Deploy different configuration per stage with Capistrano (with the multi-stage extension).
The 0.x releases of this gem are unstable, and the API/usage may change significantly, even in minor version increments.
Add this line to your application's Gemfile:
Add the following line to your Capistrano
Add the following line to your Capistrano Capfile:
For each stage, create a folder in
config/deploy/<stage>, containing all the config files specific to that
stage. On deployment (after deploy:update_code), these files will be copied to your app's root. Subfolders may be used,
but must already exist on the server. For example, if you have a folder
also need a folder
dbconfig in the root of your app.