Fix the cosign step to authenticate with the container registry
Some checks failed
CI / test (map[go:1.22.7 golangci:latest]) (push) Has been cancelled
CI / test (map[go:1.23.1 golangci:latest]) (push) Has been cancelled
Security Scan / build (push) Has been cancelled
CI / coverage (push) Has been cancelled

Change-Id: I8b5fd63128b7c661c438c9cff9e8a4a3e487712b
Signed-off-by: Cosmin Cojocar <ccojocar@google.com>
This commit is contained in:
Cosmin Cojocar 2024-10-01 15:10:45 +00:00 committed by Cosmin Cojocar
parent 50d1b4ae6b
commit 1216c9b96b

View file

@ -69,7 +69,7 @@ jobs:
push: true
build-args: GO_VERSION=1.23
- name: Sign Docker Image
run: cosign sign --yes --key /tmp/cosign.key ${DIGEST}
run: cosign sign --yes --key /tmp/cosign.key ${DIGEST} --registry-username="$secrets.DOCKER_USERNAME" --registry-password="::add-mask::$secrets.DOCKER_PASSWORD"
env:
TAGS: ${{steps.meta.outputs.tags}}
COSIGN_PASSWORD: ${{secrets.COSIGN_PASSWORD}}