Heroku 只读文件系统上的 ActiveScaffold?
ActiveScaffold 显然会在每次服务器启动时创建 public/blank.html,即使该文件已经存在(因此将其添加到版本控制中并没有帮助)。这导致我的应用程序无法在 Heroku 上启动,因为它们具有只读文件系统。
有人可以告诉我如何防止这种行为或解决它,以便我可以在 Heroku 上使用 ActiveScaffold 部署我的应用程序吗?!
ActiveScaffold apparently creates public/blank.html every time the server starts, even if that file already exists (so adding it to version control doesn't help). This is causing my application to fail to boot on Heroku, since they have a read-only file system.
Can someone please tell me how to prevent this behavior or work around it so I can deploy my app with ActiveScaffold on Heroku?!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在我急于完成这项工作时,我什至没有想到分析 ActiveScaffold 插件目录中的 init.rb 文件。其中包含对文件的 require 语句,该文件包含在服务器加载时从插件的“公共”目录复制文件的逻辑。注释掉该功能解决了我的问题(在确保我已经将这些文件放在其预期目的地之后)。
In my rush to get this working I didn't even think to analyze the init.rb file within the ActiveScaffold plugin directory. Therein contains the require statement to a file containing the logic to copy files from the plugin's "public" directory on-server-load. Commenting out that functionality fixed my problem (after ensuring that I already had those files in their intended destinations).