[英]frontend UI looks totally different and broken on heroku, how to fix this?
I'm using Amazon S3 buckets to store all of the applications assets, however, the app looks totally different in development than it does in production on heroku. 我正在使用Amazon S3存储桶来存储所有应用程序资产,但是,该应用程序在开发中看起来与在Heroku上的生产中完全不同。 Why might this be?
为什么会这样呢?
How can I get it to look the same? 如何使它看起来一样? I've worked on several apps before and never experienced this issue.
我之前曾在多个应用程序上工作,但从未遇到过此问题。 Any help would be great at this point!
此时任何帮助都将非常有用!
production.rb: production.rb:
config.paperclip_defaults = {
:storage => :s3,
:s3_credentials => {
:bucket => ENV['S3_BUCKET_NAME'],
:access_key_id => ENV['AWS_ACCESS_KEY_ID'],
:secret_access_key => ENV['AWS_SECRET_ACCESS_KEY'],
:region => ENV['REGION']
}
}
Thanks! 谢谢!
Run 跑
bundle exec rake assets:precompile RAILS_ENV=production
or
bundle exec rake assets:precompile
on your local code 在您的本地代码上
Commit the changes and deploy to heroku 提交更改并部署到heroku
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.