fix: backport maintenance-mode changes for successful failover
What does this MR do?
This is a backport of !1762 (merged) to GET 3.5.x
It allows for clean vendoring down of the fix. This fix allows for maintenance mode to be retried on a fresh toolbox pod if it is rotated before / during the execution of this task. Without this the failover playbook needs to be executed twice for a successful failover.
Related issues
Author's checklist
When ready for review, the Author applies the workflowready for review label and mention @gitlab-org/software-delivery/get-maintainers:
- Merge request:
- Corresponding Issue raised and reviewed by the GET maintainers team.
- Merge Request Title and Description are up-to-date, accurate, and descriptive
- MR targeting the appropriate branch
- MR has a green pipeline
-
MR has no new security alerts in the widget from the
Secret DetectionandIaC Scan (SAST)jobs.
- Code:
- Check the area changed works as expected across all expected permutations.
- Check that the changes work across upgrades.
- Documentation created/updated in the same MR if applicable