pub struct Environment {
pub name: EnvironmentTag,
pub gate: Option<GateDeclaration>,
pub approval_required: bool,
pub created_by: ProvenanceAuthor,
pub created_at: DateTime<Utc>,
}Expand description
An environment: R0.11’s promotion tag as a first-class record.
Logical, not physical — one deployment serves every environment from one store and one binary’s admission path; the record exists so the control plane can name the surface, declare its promotion rule, and answer “which revision serves here” from journaled data.
Fields§
§name: EnvironmentTagThe environment’s name — dev / staging / prod by
deployment-declared convention, not an enum: the R0.11 tag set,
promoted. Validated by EnvironmentTag, so the pointer surface
key (deployment:{name}) is always well-formed.
gate: Option<GateDeclaration>The gate declaration promotions into this environment must clear,
when one is declared (enforced by the control plane since wave 4;
recorded from the start). Absent: promotion is an operator act
with no gate — the dev floor.
approval_required: boolWhether promotions into this environment require a human approval
token scoped to the revision’s promotion effect id (enforced
since wave 4; the prod stance). Recorded as data so the
declaration is auditable before it is enforced.
created_by: ProvenanceAuthorWho declared the environment (human:{id}).
created_at: DateTime<Utc>When the environment was declared.