shiny-server error: bash: R: command not found

Hi all,

I installed shiny-server on the new centOS 8 machine and got " An error has occurred" message on the welcome page. The log file says:

su: ignoring --preserve-environment, it's mutually exclusive with --login
bash: R: command not found

I checked my R command, and both R and bash R work fine.

The shiny-server.log has the error:

[2020-01-09T12:44:31.321] [INFO] shiny-server - Error getting worker: Error: The application exited during initialization.

My /etc/shiny-server/shiny-server.conf file is the default version:

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;

}
}

What could be wrong?

Thanks a lot for the help!

Ying

OK, the issue went away once I exported paths to the .bashrc file under account shiny :slight_smile:

Best,

Ying