diff --git a/sign/action.yml b/sign/action.yml index 85d2837..bc34655 100644 --- a/sign/action.yml +++ b/sign/action.yml @@ -32,8 +32,8 @@ runs: shell: bash run: | docker pull cgr.dev/chainguard/cosign:latest - docker run -d --name cosign cgr.dev/chainguard/cosign:latest - docker cp cosign:/usr/bin/cosign /usr/local/bin/cosign + CONTAINER_ID=$(docker run -d cgr.dev/chainguard/cosign:latest) + docker cp "${CONTAINER_ID}":/usr/bin/cosign /usr/local/bin/cosign - name: Sign container image shell: bash diff --git a/verify/action.yml b/verify/action.yml index 647fd78..69009aa 100644 --- a/verify/action.yml +++ b/verify/action.yml @@ -30,8 +30,8 @@ runs: shell: bash run: | docker pull cgr.dev/chainguard/cosign:latest - docker run -d --name cosign cgr.dev/chainguard/cosign:latest - docker cp cosign:/usr/bin/cosign /usr/local/bin/cosign + CONTAINER_ID=$(docker run -d cgr.dev/chainguard/cosign:latest) + docker cp "${CONTAINER_ID}":/usr/bin/cosign /usr/local/bin/cosign - name: Verify container shell: bash