Quantcast
Channel: rails – The Agile Warrior
Viewing all articles
Browse latest Browse all 48

How to upgrade to Rails4 with Heroku

$
0
0

Rails migrations are never easy. But the community does it’s best to help you out. Here are some tips that helped me migrate my app:

Watch this video by Ryan Bates – Upgrading to Rails4

Check out these links

https://devcenter.heroku.com/articles/rails4-getting-started
https://devcenter.heroku.com/articles/multiple-environments

And then see if you run into any other problems like these:

Asset pipeline fails when deploying to Heroku Rails4

If you get this kind of error message

Preparing app for Rails asset pipeline
Running: rake assets:precompile
rake aborted!
could not connect to server: Connection refused
Is the server running on host “127.0.0.1″ and accepting

Try this from the command line:

> heroku labs:enable user-env-compile -a

You can get the name of your app be typing:

> heroku apps

http://stackoverflow.com/questions/16432825/heroku-precompile-assets-failed-on-rail-4-app

Images not showing up

If you deploy but no images show up try this:

production.rb

config.cache_classes = true
config.serve_static_assets = true
config.assets.compile = true
config.assets.digest = true

http://stackoverflow.com/questions/16271696/cant-get-css-working-on-heroku-using-rails-4-with-bootstrap-saas-gem

Misc

Other things to try

SampleApp::Application.configure do
  config.serve_static_assets = true
end

http://stackoverflow.com/questions/15354539/heroku-does-not-compile-files-under-assets-piplines-in-rails-4

Links that help

https://devcenter.heroku.com/articles/rails-asset-pipeline


Filed under: programming, rails Tagged: heroku, rails, rails4, upgrade

Viewing all articles
Browse latest Browse all 48

Trending Articles