Automatically create and migrate-up database schemas

Hello,

Rails is an application framework with code generation and a number of integrated features for getting started quickly.

However, when dealing with application upgrades there are a number of manual steps required admins have to perform, else Rails appslications will not run.

Want do you think about to invert the practice how to deal with database migrations? I would prefer the folowing approach:

  • generate initializers creating and migrating databases automatically

  • if you do not need this feature in development, just disable the initializer

As a result:

  • Applications will be able to run with the migration revision they do need to operate without errors

  • Applications will be able to apply migrations they are packaged with

  • Users and administrators will be happy, because Rails applications will be easier to manage

  • the number of steps will be reduced, required to manually to this and that with databases, caches and so on

Another alternative would be to add the required code to do the database related tasks automatically and leave them deactivated.

What do you think?

Best regards, Mario