fix(jzero): fix Dockerfile #13
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: goreleaser-jzero | |
on: | |
push: | |
tags: | |
- 'v*' | |
permissions: | |
contents: write | |
jobs: | |
goreleaser: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v2 | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: Set up Go | |
uses: actions/setup-go@v3 | |
with: | |
go-version: '1.22.1' | |
- name: Run GoReleaser | |
uses: goreleaser/goreleaser-action@v4 | |
with: | |
distribution: goreleaser | |
args: release --clean | |
env: | |
GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }} | |
- name: Install Task | |
uses: arduino/setup-task@v1 | |
with: | |
version: 3.x | |
repo-token: ${{ secrets.ACCESS_TOKEN }} | |
- name: Log in to Docker Hub | |
uses: docker/login-action@v2 | |
with: | |
username: ${{ secrets.DOCKER_USERNAME }} | |
password: ${{ secrets.DOCKER_PASSWORD }} | |
- name: Get version | |
id: get_version | |
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\//} | |
- name: Docker build and push | |
run: | | |
docker build -t jaronnie/jzero:${{ steps.get_version.outputs.VERSION }} . | |
docker push jaronnie/jzero:${{ steps.get_version.outputs.VERSION }} | |
docker tag jaronnie/jzero:${{ steps.get_version.outputs.VERSION }} jaronnie/jzero:latest | |
docker push jaronnie/jzero:latest | |
docker build -t jaronnie/jzero:${{ steps.get_version.outputs.VERSION }}-arm64 -f Dockerfile-arm64 . | |
docker push jaronnie/jzero:${{ steps.get_version.outputs.VERSION }}-arm64 | |
docker tag jaronnie/jzero:${{ steps.get_version.outputs.VERSION }}-arm64 jaronnie/jzero:latest-arm64 | |
docker push jaronnie/jzero:latest-arm64 |