Skip to content

Stage: mirror

The mirror stage keeps the read-only GitHub and Azure DevOps replicas in sync with GitLab (the source of truth). It is schedule-driven, not part of the per-push flow, so it never adds latency to a developer’s pipeline.

Part of the Full pipeline action map. Use the Fullscreen button on the diagram to view it edge-to-edge.

flowchart TD
  SCHED["Scheduled pipeline (2x/day)<br/>SCHEDULED_TASK=mirror<br/>or manual / API trigger"]
  KILL{"DISABLE_MIRRORS?"}
  GH["mirror:github:sync<br/>git push --force -> github.com/Freundcloud/SARC"]
  ADO["mirror:azuredevops:sync<br/>git push --force -> dev.azure.com/.../SARC"]
  PODT["mirror:podtato-images (monthly)<br/>skopeo copy upstream -> ghcr.io/calitii"]
  SLACK["notify:slack:main-failure<br/>alert on main pipeline failure"]

  SCHED --> KILL
  KILL -->|false| GH
  KILL -->|false| ADO
  KILL -->|true| SKIP["jobs evaluate to when: never"]

  class GH,ADO,PODT mirror
  class KILL gate
  class SLACK notify
  class SCHED,SKIP io
  classDef mirror fill:#768390,stroke:#444c56,color:#ffffff
  classDef gate fill:#9a6700,stroke:#5c3d00,color:#ffffff
  classDef notify fill:#1f8f6b,stroke:#0d5a42,color:#ffffff
  classDef io fill:#57606a,stroke:#32383f,color:#ffffff
JobWhat it doesWhy
mirror:github:syncForce-pushes main + tags to github.com/Freundcloud/SARC. Gated on DISABLE_MIRRORS. allow_failure: true.GitHub is a read-only replica; GitLab is authoritative so a force-push is safe.
mirror:azuredevops:syncForce-pushes main + tags to the Azure DevOps repo. Same gating.Keeps the ADO replica current for demos and parity.
mirror:podtato-imagesMonthly skopeo copy of the six upstream podtato images to ghcr.io/calitii (needs SCHEDULED_TASK=mirror-podtato). allow_failure: false.A warm DR fallback if upstream GHCR is unavailable during a demo.
notify:slack:main-failurePosts to Slack when a main-branch pipeline fails.Fast alerting on breakage.

The kill switch DISABLE_MIRRORS pauses both repo mirrors (the scheduled pipeline still fires, but the mirror jobs evaluate to when: never) — used to prevent surprise pushes during a change-over.

SARC demonstrates the same compliance pipeline on three CI platforms. The mirrors keep GitHub and ADO byte-for-byte current with GitLab without coupling them to every push — a 2×/day cadence (plus on-demand) is enough for replicas, and the kill switch keeps an operator in control.


Stages: releasemirrorpages · all stages