Add support for post deployment database migrations
Problem to solve
We need to add support for post deployment migrations to the registry CLI (documented here).
Intended users
Personas are described at https://about.gitlab.com/handbook/marketing/product-marketing/roles-personas/
Proposal
Post-deployment migrations should run with regular migrations by default. An optional flag, e.g. --skip-post-deployment, should be added to the database migrate command to skip post-deployment migrations.
-
Switch migrations files and code over to custom migration type over the rubenv/sql-migratetype !390 (merged) -
Use test fixtures, rather than production migrations for the migrator integration tests. !392 (merged) -
Add flag for post migrations to custom migration type and create logic for distinguishing from regular and post migrations !393 (merged) -
Enable the new-migration script to create post migrations !397 (merged) -
Add the logic in the migrate upcommand to skip post migrations !398 (merged) -
Update the migrate statuscommand to flag post migrations as such !401 (merged)
Documentation
- Document migrations in gitlab!43754 (merged)
Availability & Testing
Edited by Hayley Swimelar