4
我试图让一个Rails 3.2.x中的应用程序在生产环境中运行,但每次我访问部署的应用程序就抱怨资产不被编译:如何将Elastic Beanstalk获取到服务器编译的资产?
An ActionView::Template::Error occurred in home#index:
application.css isn't precompiled
vendor/bundle/gems/actionpack-3.2.11/lib/sprockets/helpers/rails_helper.rb:142:in `digest_for'
-------------------------------
Request:
-------------------------------
* URL : http://some-server.elasticbeanstalk.com/
* Parameters: {"controller"=>"home", "action"=>"index"}
* Rails root: /var/app/current
* Timestamp : 2013-01-17 17:22:55 UTC
然而,当我咨询我的EB的日志文件比如我认为这是每个部署的一部分:
Script succeeded.
Executing script: /opt/elasticbeanstalk/hooks/appdeploy/pre/11_asset_compilation.sh
Output from script: /usr/bin/ruby1.9 /usr/bin/rake assets:precompile:all RAILS_ENV=production RAILS_GROUPS=assets
我可以在生产模式运行乘客的本地实例和资产供应的罚款。有人对任何可能出错的人有所了解吗?
我遇到同样的问题,部署到AWS的Elastic Beanstalk。直到最近一切都很顺利。我试着恢复到以前的提交,但我仍然得到“application.css未预编译”500错误。 – ajporterfield