fix: add qemu and fix release multiarch #2
Workflow file for this run
This file contains hidden or 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: release | |
on: | |
push: | |
tags: | |
- '[0-9]*.[0-9]*.[0-9]*' | |
env: | |
DOCKER_BUILDX_PLATFORMS: linux/amd64,linux/arm64 | |
jobs: | |
release: | |
permissions: | |
contents: 'read' | |
id-token: "write" | |
runs-on: ubuntu-latest | |
name: release | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }} | |
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }} | |
steps: | |
- name: Checkout local | |
uses: actions/checkout@v4 | |
- name: Install Go | |
uses: actions/setup-go@v5 | |
with: | |
go-version-file: backend/go.mod | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- id: buildx-setup | |
name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
with: | |
platforms: ${{ env.DOCKER_BUILDX_PLATFORMS }} | |
- name: Fetch git tag | |
id: git-tag | |
shell: bash | |
run: | | |
set -x | |
tag=$(git describe --tags --exact --match '[0-9]*.[0-9]*.[0-9]*') | |
echo "release-version=$tag" >> $GITHUB_OUTPUT | |
- name: Build images | |
run: | | |
make build-extension TAG=${{ steps.git-tag.outputs.release-version }} | |
- name: "Docker Login" | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ env.DOCKER_USERNAME }} | |
password: ${{ env.DOCKER_PASSWORD }} | |
- name: Push images | |
run: | | |
make push-extension TAG=${{ steps.git-tag.outputs.release-version }} |