Run the dockerised e2e suite with write auth enabled (#181)
ci/woodpecker/tag/docker Pipeline failed

Write auth broke buildkit pushes in production because the dockerised e2e suite runs artifactapi with auth disabled, so no real client ever authenticated a publish.

- serve a static mock OIDC issuer; TestMain generates the key, writes the JWKS and mints tokens
- run the stack with ARTIFACTAPI_AUTH_UPLOADS=true
- authenticate each local publish the way its client does (curl Bearer/Basic, docker login, npm, gem, ansible-galaxy)
- assert publishes without a token or with a foreign-key token get 401 and anonymous reads still work
- add docker CLI, buildx and helm OCI push cases; skip the last two until unkin/artifactapi#180 lands

Reviewed-on: #181
Co-authored-by: unkin-agent <unkin-agent@unkin.net>
Co-committed-by: unkin-agent <unkin-agent@unkin.net>
This commit was merged in pull request #181.
This commit is contained in:
2026-11-08 11:08:00 +11:00
committed by BenVincent
parent 2c21667585
commit 6429e62f17
17 changed files with 239 additions and 28 deletions
+2 -2
View File
@@ -17,8 +17,8 @@ cleanup() {
}
trap cleanup EXIT
echo "==> building and starting stack (postgres, redis, minio, mockupstream(s), artifactapi)"
"${COMPOSE[@]}" up -d --build postgres redis minio mockupstream mockupstreama mockupstreamb artifactapi
echo "==> building and starting stack (postgres, redis, minio, mockupstream(s), mockoidc, artifactapi)"
"${COMPOSE[@]}" up -d --build postgres redis minio mockupstream mockupstreama mockupstreamb mockoidc artifactapi
echo "==> waiting for artifactapi health at ${API_URL}"
for i in $(seq 1 60); do