我已经在带有nginx的DigitalOcean Ubuntu14.04.5 droplet上托管了shiny-server。
闪亮的服务器工作得很好,但在我重新启动droplet以调整配置大小后停止了工作。这个问题之前没有发生过。
我尝试使用sudo start shiny-server重新启动shiny-server,但得到状态start: Job failed to start。
当我访问托管在/srv/shiny-server/上的闪亮的应用程序时,我得到以下nginx错误。
An error occurred.
Sorry, the page you are looking for is currently unavailable.
Please try again later.
If you are the system administrator of this resource then you should check the error log for details.
Faithfully yours, nginx.
Shiny-server error log:
fs.js:439
return binding.open(pathModule._makeLong(path), stringToFlags(flags), mode);
^
Error: ENOENT, no such file or directory '/var/run/shiny-server/shiny-server.pid'
at Object.fs.openSync (fs.js:439:18)
at Object.createPidFile (/opt/shiny-server/lib/core/fsutil.js:121:15)
at Object. (/opt/shiny-server/lib/main.js:82:15)
at Module._compile (module.js:456:26)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Function.Module.runMain (module.js:497:10)
at startup (node.js:119:16)
at node.js:945:3
There is no shiny-server.pid at /var/run/shiny-server/.
My /etc/shiny-server/shiny-server.conf settings:
# Instruct Shiny Server to run applications as the user "shiny"
run_as shiny;
sanitize_errors off;
# Define a server that listens on port 3838
server {
listen 3838;
# Define a location at the base URL
location / {
run_as shiny;
# 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;
}
}
I'm not sure what the problem is. Tried searching online forums too but with no luck! Please help. Thanks!发布于 2016-10-30 19:41:42
创建一个文件夹sudo mkdir /var/run/shiny-server,然后为Shiny用户sudo chown shiny:shiny /var/run/shiny-server/启用写权限
https://stackoverflow.com/questions/40326760
复制相似问题