mirror of
https://github.com/freedomofpress/dangerzone.git
synced 2025-05-08 22:41:50 +02:00
fixup! Use Docker login action
This commit is contained in:
parent
ed0ba39796
commit
6d78e3b4cb
1 changed files with 10 additions and 4 deletions
14
.github/workflows/release-container-image.yml
vendored
14
.github/workflows/release-container-image.yml
vendored
|
@ -12,12 +12,12 @@ on:
|
|||
|
||||
permissions:
|
||||
id-token: write
|
||||
packages: write
|
||||
contents: read
|
||||
attestations: write
|
||||
packages: write
|
||||
|
||||
env:
|
||||
IMAGE_REGISTRY: ghcr.io/${{ github.repository_owner }}
|
||||
REGISTRY: ghcr.io/${{ github.repository_owner }}
|
||||
REGISTRY_USER: ${{ github.actor }}
|
||||
REGISTRY_PASSWORD: ${{ github.token }}
|
||||
IMAGE_NAME: dangerzone/dangerzone
|
||||
|
@ -27,6 +27,12 @@ jobs:
|
|||
runs-on: ubuntu-24.04
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Login to GitHub Container Registry
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: ${{ env.REGISTRY }}
|
||||
username: USERNAME
|
||||
password: ${{ github.token }}
|
||||
|
||||
- name: Build and push the dangerzone image
|
||||
id: build-image
|
||||
|
@ -37,7 +43,7 @@ jobs:
|
|||
gunzip -c share/container.tar.gz | podman load
|
||||
podman push \
|
||||
dangerzone.rocks/dangerzone \
|
||||
${{ env.IMAGE_REGISTRY }}/${{ env.IMAGE_NAME }}
|
||||
${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
|
||||
DIGEST=$(podman images --filter "reference=dangerzone.rocks/dangerzone" --format "{{ .Digest }}")
|
||||
echo "Digest: ${DIGEST}"
|
||||
echo "digest=${DIGEST}" >> "$GITHUB_OUTPUT"
|
||||
|
@ -45,6 +51,6 @@ jobs:
|
|||
- name: Generate artifact attestation
|
||||
uses: actions/attest-build-provenance@v1
|
||||
with:
|
||||
subject-name: ${{ env.IMAGE_REGISTRY }}/${{ env.IMAGE_NAME }}
|
||||
subject-name: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
|
||||
subject-digest: "${{ steps.build-image.outputs.digest }}"
|
||||
push-to-registry: true
|
||||
|
|
Loading…
Reference in a new issue