This repository has been archived by the owner on Apr 19, 2024. It is now read-only.
build(deps): bump golang from 1.21.5 to 1.21.6 #71
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: ci | |
on: | |
push: | |
branches: | |
- "main" | |
tags: | |
- "v*" | |
pull_request: | |
branches: | |
- "main" | |
env: | |
REGISTRY: ghcr.io | |
IMAGE_NAME: islishude/geth | |
jobs: | |
main: | |
concurrency: "build" | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
packages: write | |
id-token: write | |
steps: | |
- name: checkout repo | |
uses: actions/checkout@v4 | |
- name: Install cosign | |
if: ${{ github.ref_type == 'tag' }} | |
uses: sigstore/cosign-installer@v3 | |
- name: Login to Github Registry | |
uses: docker/login-action@v3 | |
if: github.event_name != 'pull_request' | |
with: | |
registry: ${{ env.REGISTRY }} | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: Docker meta | |
id: docker-meta | |
uses: docker/metadata-action@v5 | |
with: | |
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} | |
tags: | | |
type=semver,pattern={{version}} | |
type=ref,event=branch | |
- name: Build with tag and push | |
id: docker-build-push | |
uses: docker/build-push-action@v5 | |
with: | |
push: ${{ github.ref_type == 'tag' }} | |
pull: true | |
platforms: linux/amd64,linux/arm64 | |
tags: ${{ steps.docker-meta.outputs.tags }} | |
labels: ${{ steps.docker-meta.outputs.labels }} | |
annotations: ${{ steps.docker-meta.outputs.annotations }} | |
cache-from: type=gha | |
cache-to: type=gha,mode=max | |
- name: Sign the published Docker image | |
if: ${{ github.ref_type == 'tag' }} | |
env: | |
TAGS: ${{ steps.docker-meta.outputs.tags }} | |
DIGEST: ${{ steps.docker-build-push.outputs.digest }} | |
run: echo "${TAGS}" | xargs -I {} cosign sign --yes {}@${DIGEST} |