5.6 KiB
5.6 KiB
1. Introduction
Overview
Compatibility rollout for Caddy 2.11.1 is already reflected in the build
default (Dockerfile currently sets ARG CADDY_VERSION=2.11.1).
This plan is now focused on rollout verification and regression-proofing, not changing the default ARG.
Objective
Establish deterministic, evidence-backed gates that prove published images and
security artifacts are fresh, digest-bound, and aligned across registries for
the Caddy 2.11.1 rollout.
2. Current State (Verified)
Dockerfiledefault is alreadyCADDY_VERSION=2.11.1.ARCHITECTURE.mdnow reports Caddy2.11.1.- Existing scan artifacts can become stale if not explicitly tied to pushed digests.
3. Technical Specification (EARS)
- WHEN image builds run without an explicit
CADDY_VERSIONoverride, THE SYSTEM SHALL continue producing Caddy2.11.1. - WHEN an image tag is pushed, THE SYSTEM SHALL validate index digest parity between GHCR and Docker Hub for that same tag.
- WHEN multi-arch images are published, THE SYSTEM SHALL validate per-arch digest parity across GHCR and Docker Hub for each platform present.
- WHEN vulnerability and SBOM scans execute, THE SYSTEM SHALL scan
image@sha256:<index-digest>instead of mutable tags. - WHEN scan artifacts are generated, THE SYSTEM SHALL prove artifacts were produced after the push event in the same validation run.
- IF a verification gate fails, THEN THE SYSTEM SHALL block rollout sign-off until all gates pass.
4. Scope and Planned Edits
In scope
docs/plans/current_spec.md(this plan refresh).ARCHITECTURE.mdversion sync is already complete (2.11.1); no pending update is required in this plan.- Verification workflow/checklist updates needed to enforce deterministic gates.
Out of scope
- No functional Caddy build logic changes unless a verification failure proves they are required.
- No plugin list or patch-scenario refactors.
5. Deterministic Acceptance Gates
Gate 1: Digest Freshness (pre/post push)
- Capture pre-push index digest for target tag on GHCR and Docker Hub.
- Push image.
- Capture post-push index digest on GHCR and Docker Hub.
- Pass criteria:
- Post-push index digest changed as expected from pre-push (or matches intended new digest when creating new tag).
- GHCR and Docker Hub index digests are identical for the tag.
- Per-arch digests are identical across registries for each published platform.
Gate 2: Digest-Bound Rescan
- Resolve the post-push index digest.
- Run all security scans against immutable ref:
ghcr.io/<owner>/<repo>@sha256:<index-digest>- Optional mirror check against Docker Hub digest ref.
- Pass criteria:
- No scan uses mutable tags as the primary target.
- Artifact metadata and logs show digest reference.
Gate 3: Artifact Freshness
- Record push timestamp and digest capture timestamp.
- Generate SBOM and vuln artifacts after push in the same run.
- Pass criteria:
- Artifact generation timestamps are greater than push timestamp.
- Artifacts are newly created/overwritten in this run.
- Evidence ties each artifact to the scanned digest.
Gate 4: Evidence Block (mandatory)
Every validation run must include a structured evidence block with:
- Tag name.
- Index digest.
- Per-arch digests.
- Scan tool versions.
- Push and scan timestamps.
- Artifact file names produced in this run.
6. Implementation Plan
Phase 1: Baseline Capture
- Confirm current
Dockerfiledefault remains2.11.1. - Capture pre-push digest state for target tag across both registries.
Phase 2: Docs Sync
- Confirm
ARCHITECTURE.mdremains synced at Caddy2.11.1.
Phase 3: Push and Verification
- Push validation tag.
- Execute Gate 1 (digest freshness and parity).
- Execute Gate 2 (digest-bound rescan).
- Execute Gate 3 (artifact freshness).
- Produce Gate 4 evidence block.
Phase 4: Sign-off
- Mark rollout verified only when all gates pass.
- If any gate fails, open follow-up remediation task before merge.
7. Acceptance Criteria
- Plan and execution no longer assume Dockerfile default is beta.
- Objective is rollout verification/regression-proofing for Caddy
2.11.1. ARCHITECTURE.mdversion metadata is included in required docs sync.- Digest freshness gate passes:
- Pre/post push validation completed.
- GHCR and Docker Hub index digest parity confirmed.
- Per-arch digest parity confirmed.
- Digest-bound rescan gate passes with
image@sha256scan targets. - Artifact freshness gate passes with artifacts produced after push in the same run.
- Evidence block is present and complete with:
- Tag
- Index digest
- Per-arch digests
- Scan tool versions
- Timestamps
- Artifact names
8. PR Slicing Strategy
Decision
Single PR.
Trigger Reasons
- Scope is narrow and cross-cutting risk is low.
- Verification logic and docs sync are tightly coupled.
- Review size remains small and rollback is straightforward.
PR-1
- Scope:
- Refresh
docs/plans/current_spec.mdto verification-focused plan. - Sync
ARCHITECTURE.mdCaddy version metadata. - Add/adjust verification checklist content needed for gates.
- Refresh
- Dependencies:
- Existing publish/scanning pipeline availability.
- Validation gates:
- Gate 1 through Gate 4 all required.
9. Rollback and Contingency
- If verification updates are incorrect or incomplete, revert PR-1.
- If rollout evidence fails, hold release sign-off and keep last known-good digest as active reference.
- Re-run verification with corrected commands/artifacts before reattempting sign-off.