migrations: Add (rudimentary) docs for rollback
Created by: efritz
This PR adds:
- a
validate
command to bothsg migration
and themigrator
service, which simply runs the validation routine that the applications do on startup, and exits with a status of zero if the database is clean and up to date and one otherwise. - a
leaves
command tosg migration
which takes a commit and returns the last migrations defined at that time. - documentation on how to roll back a postgres database with these two new tools
Reviewers: Please give special attention to the doc page and suggest where I can steal copy from other migrations work we've been doing lately.
Edit: Non-docs work was pulled out into #30860.