Console app for running migrations on multiple databases in one go
##Purpose: To run migrations on multiple databases simultaneously, using command line.
Clone the repository and run composer install.
env.php. Put your configuration into the config file.
You will need one primary database, that contains usernames, passwords and database names for all databases you want to run migrations on.
Default configuration assumes that your "main" database name is
companydatabases that has a
databasesettings table, and it will read from
You may change the name of your "main" database in the config file.
Example table structure will look like this (please notice the
In the root folder of the application execute
php console.php. This will give you access to three commands:
The first run of
migrate:check command will check if
migrations table exist, and create it if it doesn't.
- generate new migrations using the
- check status of your migrations with
- run your migrations using
- check if the migration run successfully