我正在尝试使用dokku-persistent-storage,因此我的 rails 应用程序的上传文件保留在服务器上,但我不太了解如何构建路径,因为我是Dokku和Docker的新手。(我在 Digital Ocean 上的 Ubuntu droplet 上运行它)
我不确定它是否应该是这样的:
[SERVER IP ADDRESS]/home/dokku/myapp/public_folder
或者
/home/dokku/myapp/public_folder
或者如果我离开了,它应该是完全不同的东西。
这就是 github 部分所说的:
在您的应用程序文件夹 (/home/dokku/app_name) 中创建一个名为 PERSISTENT_STORAGE 的文件。
在此文件中,每行列出一个要挂载的卷映射/卷。例如:
/host/path:/container/path
/another/container/path
上面的示例将导致在部署和 docker run 期间将以下参数传递给 docker:
-v /host/path:/container/path -v /another/container/path
可以在此处找到有关 docker 卷的移动信息:http: //docs.docker.io/en/latest/use/working_with_volumes/