This repository has been archived by the owner on Apr 22, 2024. It is now read-only.
Publish docker images to ghcr (#69) #2
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: Publish | |
on: | |
push: | |
tags: ['v[0-9]+.[0-9]+.[0-9]+**'] # Ex. v0.2.0, v0.2.1-rc2 | |
workflow_dispatch: {} | |
env: | |
GOPROXY: https://proxy.golang.org | |
jobs: | |
publish: | |
runs-on: ubuntu-latest | |
steps: | |
- name: "Set release tag" | |
if: ${{ github.ref_type == 'tag' }} | |
shell: bash | |
run: | | |
# Set the VERSION to force the version of the Docker images | |
echo "VERSION=${GITHUB_REF_NAME}" >> "$GITHUB_ENV" | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version-file: go.mod | |
- run: make check | |
- uses: docker/login-action@v3 | |
with: | |
registry: ghcr.io | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- run: make docker-push |