Interview Prep/Git & GitHub/Recovery and incident handling

After recovery, what do you change so a force-push to main cannot happen again?

AdvancedProductionRecovery and incident handling
Answer

Protect main with a ruleset that blocks non-fast-forward updates and deletions with an empty bypass list, review who had admin rights, alert on audit-log events for ref force-pushes, and write the postmortem including how detection worked.

All Git & GitHub questions Roadmap: Git & GitHub

More on Recovery and incident handling