diff --git a/.github/workflows/vex.yml b/.github/workflows/vex.yml index 7f838c95..a58a0341 100644 --- a/.github/workflows/vex.yml +++ b/.github/workflows/vex.yml @@ -111,7 +111,7 @@ jobs: --file "/vex/stackyard-$arch.vex.json" \ --predicate-type https://openvex.dev/ns/v0.2.0 \ --referrer \ - "registry://${IMAGE#docker.io/}@$(cat "$RUNNER_TEMP/digest-$arch")" + "${IMAGE}@$(cat "$RUNNER_TEMP/digest-$arch")" done env: # Pin by digest. This program holds the Docker Hub token. diff --git a/test/repo/release-workflow.test.js b/test/repo/release-workflow.test.js index de086090..ac6c47c5 100644 --- a/test/repo/release-workflow.test.js +++ b/test/repo/release-workflow.test.js @@ -337,6 +337,8 @@ test('the Scout program is pinned by digest and attaches by referrer', () => { assert.match(attach.env.SCOUT_IMAGE, /^docker\.io\/docker\/scout-cli:[\d.]+@sha256:[0-9a-f]{64}$/); assert.match(attach.run, /--referrer\b/, 'attaching into the index changes the signed digest'); assert.match(attach.run, /--org "\$NAMESPACE"/, 'Scout refuses to attach without the organisation'); + assert.match(attach.run, /"\$\{IMAGE\}@\$\(cat "\$RUNNER_TEMP\/digest-\$arch"\)"/); + assert.doesNotMatch(attach.run, /registry:\/\//, 'attestation add reads the scheme as a host name'); assert.match(attach.run, /--predicate-type https:\/\/openvex\.dev\/ns\/v0\.2\.0/); assert.match(attach.run, /--file "\/vex\/stackyard-\$arch\.vex\.json"/); assert.match(vexStep('Prepare the VEX statements').run, /"\$RUNNER_TEMP\/stackyard-\$arch\.vex\.json"/);