How to Approve a Production Deploy in CircleCI
A type: approval job pauses the workflow until someone approves it in the CircleCI UI.
Insert an approval job between build and deploy and make the deploy require it. The workflow holds until a person clicks approve.
Hold for approval
The deploy job depends on the approval job, so nothing ships until approved.
.circleci/config.yml
version: 2.1
workflows:
ship:
jobs:
- build
- hold:
type: approval
requires:
- build
- deploy:
requires:
- hold
filters:
branches:
only: mainNotes
- The approval job has no steps; it exists purely as a gate.
- Restrict who can approve by limiting workflow access at the org level.
- Combine with branch filters so the gate only appears on main.
Related guides
How to Use a Context for Secrets in CircleCIShare secrets across CircleCI projects with a context, attach it to a workflow job, and restrict it with secu…
How to Schedule a Nightly Pipeline in CircleCIRun a CircleCI pipeline on a nightly cron with a scheduled trigger, passing pipeline parameters so the schedu…