Geo seems to be missing a migration
After removing our secondary Geo instance (running on Kubernetes / using the GitLab Operator) for testing purposes, we're unable to get it back online. The dependencies init container keeps telling us there is a pending migration but when migrating by either executing gitlab-rake db:migrate:geo inside the toolbox pod or starting the migration pod, it tells us there are no pending migrations and all migrations are up.
It seems there is missing a migration because the output of db:migrate:status:geo contains 157 lines and when running the dependencies init container against an empty database, it tells us there are 158 pending migrations.
After figuring out which scripts and commands are run to check for pending migrations and executing them, it looks like there is a mismatch between ee/db/migrations and ee/db/schema_migrations. In schema_migrations, the file 20220202101354 is present but there is no corresponding migration code in ee/db/migrations so there is nothing to migrate.
The reason this is not visible in the output of the db:migrate:status:geo command might have to do with #558156