MVP-4.1 · CI gates deploys on tests + trivy + cosign :sha + build args #287

Open
opened 2026-09-20 20:19:45 +00:00 by sharang · 0 comments
Owner

Goal

CI can currently deploy an image that never passed its tests, is unscanned and is signed only on a best-effort basis. Before anything reaches production, the pipeline has to be the gate.

What to change

In .gitea/workflows/ci.yml:

  • Deploy jobs get needs: check, and check also runs on main (P0).
  • Test every crate, plus the Mongo integration tests (tenant_isolation, tenant_status_middleware, werkbank_api, demo_seed — MVP-1.13).
  • Trivy image scan (P0).
  • cosign signs :sha-*, and a signing failure fails the job.
  • Build args for the sha and the build date, feeding /version (MVP-1.1).

Acceptance

  • A failing test or a Trivy finding above the threshold blocks the deploy job.
  • check runs on pushes to main, not only on PRs.
  • Mongo integration tests run with a service container in CI.
  • Every published image is cosign-signed; a signing failure fails the workflow.
  • /version on stage reports the sha and date of the deployed build.
  • Nightly: the firmwerk git auth in nightly.yml is fixed so the nightly job runs (see #188).
## Goal CI can currently deploy an image that never passed its tests, is unscanned and is signed only on a best-effort basis. Before anything reaches production, the pipeline has to be the gate. ## What to change In `.gitea/workflows/ci.yml`: - Deploy jobs get `needs: check`, and `check` also runs on `main` (**P0**). - Test every crate, plus the Mongo integration tests (`tenant_isolation`, `tenant_status_middleware`, `werkbank_api`, `demo_seed` — MVP-1.13). - Trivy image scan (**P0**). - cosign signs `:sha-*`, and a signing failure fails the job. - Build args for the sha and the build date, feeding `/version` (MVP-1.1). ## Acceptance - [ ] A failing test or a Trivy finding above the threshold blocks the deploy job. - [ ] `check` runs on pushes to `main`, not only on PRs. - [ ] Mongo integration tests run with a service container in CI. - [ ] Every published image is cosign-signed; a signing failure fails the workflow. - [ ] `/version` on stage reports the sha and date of the deployed build. - [ ] Nightly: the firmwerk git auth in `nightly.yml` is fixed so the nightly job runs (see #188).
sharang added this to the Production MVP milestone 2026-09-20 20:19:45 +00:00
sharang added the infrastructuresecurity labels 2026-09-20 20:19:45 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: platform/pruefwerk#287