如何使Golem应用程序出现在特定的URL路由中

问题描述

我们让 golem 软件包自动为我们创建一个Dockerfile,并可以运行Docker映像并在根目录http://localhost:3838/?...

上查看该应用程序

但是我们希望该应用程序出现在http://localhost:3838/myApp/v1/?...这样的子目录中,以便我们可以为Apache设置必要的代理,并使该应用程序和其他应用程序都可以在单个服务器上使用。

我们可以手动编辑Dockerfile以复制包含以下信息的Shiny-server.conf文件:

# Define a server that listens on port 3838
server {
  listen 3838;
  # Define a location at the base URL
  location /myApp/v1/ {
    # 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;
  }
}

上述解决方案感觉很像黑客,我们希望 golem 内有功能,这些功能将使我们能够设置应用程序出现的子目录。

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)