Security requires two people for prod deploys: the author cannot approve. Configure it.
BeginnerScenarioSecrets, OIDC & Environments
Answer
Situation read → Separation of duties.
What I'd do →
- Prod environment: required reviewers = team
release-approvers, enable "Prevent self-review", disable admin bypass. - Deployment branches:
mainand tag patternv*only. - Branch protection on
mainwith required PR reviews so the code itself had a second reviewer.
Why → Prevent self-review blocks the person who triggered the run from approving it.
Interview tip → Mention audit trail: approvals are recorded on the deployment and in the audit log.
More on Secrets, OIDC & Environments
You find AWS access keys stored as repo secrets in 25 repos. Plan the migration.IntermediateA developer asks to print a secret in the log "just once" to debug. What do you do instead?BeginnerStaging and prod need different database URLs and different AWS roles, using one workflow. How?BeginnerWrite the AWS trust policy for a role used only by the prod deploy job of one repo.IntermediatePR workflows need read-only AWS access for `terraform plan`, including from same-repo branches. How do you set trust?AdvancedA team stores a 200 KB kubeconfig and certificates as secrets and hits the size limit. What do you recommend?Intermediate