diff --git a/.github/workflows/build-release-binary.yml b/.github/workflows/build-release-binary.yml index 9a56e1e..f449394 100644 --- a/.github/workflows/build-release-binary.yml +++ b/.github/workflows/build-release-binary.yml @@ -197,21 +197,33 @@ jobs: - name: Build maker docker image run: | + VERSION=${{ github.event.release.tag_name }} + + if [ "$VERSION" = "preview" ]; then + VERSION=latest + fi + docker buildx build \ --push \ --platform linux/amd64,linux/arm64,linux/arm/v7 \ --label "org.opencontainers.image.source https://github.com/${{ github.repository }}" \ - --tag ghcr.io/${{ github.repository }}/maker:${{ github.event.release.tag_name }} \ + --tag ghcr.io/${{ github.repository }}/maker:${VERSION} \ --build-arg BINARY_PATH=maker \ . - name: Build taker docker image run: | + VERSION=${{ github.event.release.tag_name }} + + if [ "$VERSION" = "preview" ]; then + VERSION=latest + fi + docker buildx build \ --push \ --platform linux/amd64,linux/arm64,linux/arm/v7 \ --label "org.opencontainers.image.source https://github.com/${{ github.repository }}" \ - --tag ghcr.io/${{ github.repository }}/taker:${{ github.event.release.tag_name }} \ + --tag ghcr.io/${{ github.repository }}/taker:${VERSION} \ --build-arg BINARY_PATH=taker \ . diff --git a/.github/workflows/release-docker.yml b/.github/workflows/release-docker.yml index 0aacfd3..fb1d3ad 100644 --- a/.github/workflows/release-docker.yml +++ b/.github/workflows/release-docker.yml @@ -58,22 +58,34 @@ jobs: - name: Build maker docker image run: | + VERSION=${{ github.event.inputs.release_tag }} + + if [ "$VERSION" = "preview" ]; then + VERSION=latest + fi + docker buildx build \ --push \ --platform linux/amd64,linux/arm64,linux/arm/v7 \ --label "org.opencontainers.image.source https://github.com/${{ github.repository }}" \ - --tag ghcr.io/${{ github.repository }}/maker:${{ github.event.inputs.release_tag }} \ + --tag ghcr.io/${{ github.repository }}/maker:${VERSION} \ --build-arg BINARY_PATH=maker \ . - name: Build taker docker image run: | + VERSION=${{ github.event.release.tag_name }} + + if [ "$VERSION" = "preview" ]; then + VERSION=latest + fi + docker buildx build \ --push \ --platform linux/amd64,linux/arm64,linux/arm/v7 \ --label "org.opencontainers.image.source https://github.com/${{ github.repository }}" \ - --tag ghcr.io/${{ github.repository }}/taker:${{ github.event.inputs.release_tag }} \ + --tag ghcr.io/${{ github.repository }}/taker:${VERSION} \ --build-arg BINARY_PATH=taker \ .