Loading
test(e2e): pull with the CI job payload credential (monolith/S16 plan: 3/6)
Summary
- Problem: monolith/S16's criteria 7 and 8 have catalog rows (Step 2, !3816 (merged)), both
blocked: glee claimed CI jobs as their runner but reported no executor, so GitLab put no Artifact Registry credential in the payload, and glee could not pull with one. - Impact: none for users; the e2e suite now covers the CI image pull credential that Step 1 (gitlab-org/gitlab!268444 (merged)) added.
- Change: Step 3 of the monolith/S16 plan.
- glee goes to v0.99.0, which adds
gitlab.JobToken{Executor: "docker"}andar.JobPullCredential(glee!256 (merged)). e2e/scenarios/docker_ci_pull.gopulls with the payload credential, as a user with a grant, which succeeds, and as one without, which is refused and masked. Both need the flag throughe2e.Config.- The
uiprofile declaresci_artifact_registry_pull_credentials, andcaproni-run.shturns it on with the rig's other flags. - Both rows become
automatableandimplemented, and the section intro drops the dependency. - A
limitations.mdentry records under Green does not attest: what glee, pulling in place of a GitLab Runner, does not show.
- glee goes to v0.99.0, which adds
- Downsides: the rows do not show a runner applying the credential to the pre-job pull, nor
services:; the limitations entry names both, and each scenario'sUnprovendoes too.
Plan and spec amendments
- Step 3 in the plan now builds the scenarios on glee: glee!256 (merged) adds the executor and the payload credential, and the rig's profile turns the flag on. It no longer has the job's
image:name an Artifact Registry image: the provider does not readimage:, and nothing runs the job.
Checklist
- Ran it:
e2e:capronion the rig (https://gitlab.com/gitlab-org/ops/artifact-registry/-/jobs/17899508765): green, 336 of 337 scenarios run, ande2e.docker.auth.ci-image-pullande2e.docker.auth.ci-image-pull-deniedboth pass, so the rig's monolith puts the credential in the payload for the registry's host. Locally:glee catalog generate --check,glee check(337 scenarios; both rows covered),go vetandgolangci-lintwith thee2etag on the new file. - Interfaces and data: none; scenarios, rig profile and catalog only.
- Failure: a payload without a credential for the registry's host fails the
ar.JobPullCredentialfixture, naming the host and the credentials the payload holds. - Rollout: n/a; the flag is enabled in the rig only.
- Hot path: no.
- Database: no.
- Security: no service change; the scenario logs in with the payload's credential, as a runner does, and glee redacts it.
- ADRs: ADR-020 (the token the credential carries) and ADR-021 (the job's user's grant decides); the rows assert both.
- E2E: flips
e2e.docker.auth.ci-image-pullande2e.docker.auth.ci-image-pull-deniedtoautomatableandimplemented, per Writing a row. - Simplicity: a GitLab Runner on the rig would run the Kubernetes executor, which S16 skips, so glee stays the runner; the scenarios use glee's existing steps.
Closes #1864 (closed)
Edited by Daniel Prause