Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .github/actions/push/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@ inputs:
required: false
type: string

outputs:
digest:
description: "The digest of the built image"
value: ${{ steps.build.outputs.digest }}

runs:
using: "composite"
steps:
Expand Down Expand Up @@ -67,6 +72,7 @@ runs:
endpoint: builders

- name: Build and push
id: build
uses: docker/build-push-action@471d1dc4e07e5cdedd4c2171150001c434f0b7a4 # [email protected]
with:
context: .
Expand Down
13 changes: 13 additions & 0 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ jobs:
push:
name: Push Docker
runs-on: ubuntu-latest
permissions:
id-token: write
attestations: write
packages: write
steps:
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # [email protected]
Expand All @@ -23,6 +27,15 @@ jobs:
echo TAGS="ghcr.io/${{ github.repository }}/immutable-geth:unstable-$BUILD_TIMESTAMP-git.$SHORT_SHA" >> $GITHUB_ENV

- uses: ./.github/actions/push
id: push
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
tags: ${{ env.TAGS }}

- name: Attest
uses: actions/attest-build-provenance@v2
id: attest
with:
subject-name: ghcr.io/${{ github.repository }}/immutable-geth
subject-digest: ${{ steps.push.outputs.digest }}
push-to-registry: false
13 changes: 13 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ jobs:
push:
name: Push Docker
runs-on: ubuntu-latest
permissions:
id-token: write
attestations: write
packages: write
steps:
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # [email protected]
Expand All @@ -16,6 +20,15 @@ jobs:
run: echo "TAG=$(echo ${GITHUB_REF} | sed 's/refs\/tags\///')" >> $GITHUB_ENV

- uses: ./.github/actions/push
id: push
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
tags: "ghcr.io/${{ github.repository }}/immutable-geth:latest,ghcr.io/${{ github.repository }}/immutable-geth:${{ env.TAG }}"

- name: Attest
uses: actions/attest-build-provenance@v2
id: attest
with:
subject-name: ghcr.io/${{ github.repository }}/immutable-geth
subject-digest: ${{ steps.push.outputs.digest }}
push-to-registry: false
Loading