More Than One Approver, and an Apply That Waits: Tuning the Approval Gate
By Chirag Panchal · Founder & Lead Architect · · 6 min read
The approval gate has two per-environment dials: how many different people must approve (one to five), and whether a completed approval queues the apply immediately or waits until someone presses Start apply. How the single decision rule works, what always blocks an approval (policy, a missing or stale plan, the person who started the run), and how a later approval is refused if the plan changed.
Development Status & Architectural Evolution: InfraOrcinus is in active development. Architecture specifications, internal interfaces, and operational protocols described herein reflect our current engineering design and are continuously refined to make InfraOrcinus robust, resilient, and enterprise-grade.
The default approval in InfraOrcinus is simple and strict: a run plans, stops, and one person other than the one who started it approves, and that approval queues the apply. For most environments that is exactly right.
Production sometimes needs more. A change to a shared network might warrant two reviewers. A change to a regulated system might need approval granted in the morning and applied inside a maintenance window in the evening. Two settings on the environment cover both, and both default to today's behaviour, so nothing changes until someone turns them on. This article describes them and the rule underneath.
An earlier article describes the named approval gate itself; this one is about the two dials on it.
1. One Rule, Written Once
Who may approve a run is decided in one place, as a pure function of facts: the run, the caller, the environment's settings, the policy result and the stored plan. The approve and reject endpoints enforce its answer, and the screens display the same answer. So the button is greyed out for exactly the reason the server would refuse, and the message is the server's own.
The rule, in the order it is applied:
- Only a run waiting on approval can be decided.
- Deciding needs a writer, and an administrator when the environment requires one. A read-only role can do neither.
- A plan-only run or environment cannot be approved at all, because it cannot apply.
- A mandatory policy violation, or a policy check that did not complete, blocks approval. It never blocks rejecting.
- The person who started the run cannot approve it. They may reject it, which applies nothing.
- You cannot approve twice.
- With plans stored, a run with no plan on record cannot be approved, and neither can one whose plan is older than the configured limit, because an old plan may no longer describe what applying would do.
Refusals carry a code and a message that is safe to show, so a person is told why.
2. Dial One: How Many Approvals
An environment can require one to five approvals. They must be from distinct people, none of them the person who started the run. The default is one.
- The first approval binds the plan. It records the digest of the plan the approver reviewed (and of the saved plan file, where the engine has one).
- Later approvals must match it. If the plan changed after an earlier approval, the next approval is refused with "the plan changed after an earlier approval; re-run the plan". Two people cannot end up approving two different things under one run.
- The UI shows progress. A run with three approvals required and one recorded says "1 of 3 approvals recorded", and the button reads Approve until the final approval, when it reads Approve & Apply.
Approvals required is separate from who may approve. An environment can also require an administrator, so "three approvals, and every approver an administrator" is a valid setting.
3. Dial Two: Hold the Apply
By default, the final approval queues the apply at once. With hold apply on, the final approval is recorded but nothing starts. The run shows that it is ready, and someone with write access presses Start apply when they choose.
That separates two decisions that are often tied together unnecessarily:
- Is this change acceptable? answered by the approvers, any time after the plan.
- When does it happen? answered by whoever runs the maintenance window.
Start apply is not a way around anything. It is only available once the required approvals are in, and the decision is re-evaluated at that moment: a policy violation that appears late, or a policy check that no longer completes, clears the ready state even for a run that was already fully approved.
4. The Apply Still Checks What Was Approved
Whatever the settings, the run is bound to what was reviewed. At apply time the server compares the plan it is about to apply with the digest the approval recorded, and refuses a plan that no longer matches. For Git-backed blueprints the digest includes the source revision, so the same plan JSON from a different checkout is not treated as the same approval.
Holding an apply therefore carries a real obligation: if the plan or the code underneath it changes during the wait, the answer is to re-run the plan and approve again. A long hold is also bounded by the plan-age limit, if one is configured.
5. Choosing Settings
- Default (one approval, no hold) suits most environments: a second person, a plan they saw, an immediate apply.
- Two approvals suits shared infrastructure where a wrong change affects other teams, and where one reviewer might lack the context.
- Hold apply suits maintenance windows, and environments where the approver is not the person who should press the button.
- Required administrator suits production and anything touching identity or networking.
Match the number to your staffing. Requiring three approvals from a team of three means the person who started the run can never ship their own change without finding two colleagues, and that is the intent, but plan for holidays.
Summary
Two per-environment settings tune the approval gate without weakening it: one to five distinct approvals, and an optional hold between the final approval and the apply. One rule decides every approval, with the starter excluded, mandatory policy, a missing or stale plan and a changed plan all refusing. The first approval binds the plan, later ones must match it, and the apply refuses anything that no longer matches what was approved.