I have installed Shiny Server in my local machine following the steps here.
I also manage to get the default sample app running at http://127.0.0.1:3838/sample-apps/hello/
But when I want to run the app that I have been working on RStduio, I get this error,
An error has occurred
The application failed to start.
The application exited during initialization.
Error in library(plyr) : there is no package called ‘plyr’ Calls: runApp ... sourceUTF8 -> eval -> eval -> ..stacktraceon.. -> library Execution halted
I have installed all the packages via RStudio and they are in this directory,
/home/tealou/R/x86_64-pc-linux-gnu-library/3.2/
I can see plyr is already installed.
.../3.2/
plyr/
But why the Shiny Server does not pick up the packages in the directory above?
Where should I install the packages for the server then? and how?
Any ideas?
EDIT:
# Instruct Shiny Server to run applications as the user "shiny"
run_as shiny;
# Define a server that listens on port 3838
server {
listen 3838;
# Define a location at the base URL
location / {
# Host the directory of Shiny Apps stored in this directory
site_dir /srv/shiny-server;
# Log all Shiny output to files in this directory
log_dir /var/log/shiny-server;
# When a user visits the base URL rather than a particular application,
# an index of the applications available in this directory will be shown.
directory_index on;
PATH=/home/tealou/R/x86_64-pc-linux-gnu-library/3.2/
}
}