加载闪亮的应用程序

时间:2018-02-18 16:31:13

标签: shiny shiny-server

我在远程Centos服务器上安装了shiny-server。 闪亮的配置看起来像这样:

# Instruct Shiny Server to run applications as the user "shiny"
run_as <user>;
# 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;
}
}

每当我将闪亮的应用文件放在/srv/shiny-server文件夹上时,它都能很好地加载。 但我尝试创建一个文件夹,然后使用文件路径调用不同的应用程序,但它们需要永远加载。

为了使用路径在一台服务器上部署多个应用程序,是否缺少某些内容?

1 个答案:

答案 0 :(得分:0)

我后来发现更快的方法是在/srv/shiny-server中创建一个文件夹,然后添加一个符号链接:/opt/shiny-server/foldername 然后,您将应用程序存储在第二个位置,并从第一个位置调用它们。 加载速度现在好一点。当然,它还取决于代码的效率。

相关问题