capistrano / rails

Official Ruby on Rails specific tasks for Capistrano
http://www.capistranorb.com/
MIT License
867 stars 270 forks source link

Migrate all environments on same server #215

Closed papilip closed 6 years ago

papilip commented 6 years ago

Hello, I open this issue for discuss about a new feature for migrate all environments in the same server.

Some explanation: We have the same code with many environments for distinguish databases. When we have a migration, we must migrate all databases. We have modify you code for add this feature at https://github.com/quimeo/capistrano-rails/blob/master/lib/capistrano/tasks/migrations_all_dbs.rake

First : Do you want a PR ? Second : Do you think you can add this feature ?

mattbrictson commented 6 years ago

Hi, thanks for opening an issue.

This sounds like a very specialized use case. It is the first time I've heard Rails environments being used in this way. I don't think this is general enough that it should be included in the capistrano-rails gem.

My goal with this gem is to promote the most common/recommend way to deploy Rails. For Rails projects that have non-trivial deviations from the standard practices, my general suggestion is to write custom tasks for those projects.

Because of this, I don't feel I can accept a PR for this or add this feature at this time.

However, you can add this to your own projects by placing the code you written (with minor edits) to e.g. lib/capistrano/tasks/migrating_all_dbs.rake. Or, if you need to use this across many projects, you could publish it as your own gem. Let me know if you need any help on that.