On the Amazon AMI I can install from inside R, but then I have this problem:
Installing package into ‘/usr/lib64/R/library’
(as ‘lib’ is unspecified)
Warning in install.packages("jsonlite", repos = "http://cran.r-project.org") :
'lib = "/usr/lib64/R/library"' is not writable
Would you like to use a personal library instead? (y/n)
I can install it this way also:
wget https://cran.r-project.org/src/contrib/jsonlite_1.5.tar.gz
sudo R CMD INSTALL jsonlite_1.5.tar.gz
which probably is the best way, or run R as sudo..