1
0
mirror of https://github.com/gilbN/theme.park.git synced 2024-11-20 01:52:32 +01:00

update tag env

This commit is contained in:
GilbN 2022-10-23 13:06:31 +02:00
parent c45dbf61ca
commit 33e9c6a970

View File

@ -45,7 +45,7 @@ jobs:
echo "VERSION=${{ github.event.release.tag_name }}" >> $GITHUB_ENV
echo "platform=${ARCHITECTURE//-/\/}" >> $GITHUB_ENV
echo "cache=${GITHUB_REPOSITORY,,}:${{ github.ref_name }}-cache-${{ matrix.architecture }}" >> $GITHUB_ENV
echo "tag=${GITHUB_REPOSITORY,,}:${{ github.ref_name }}-${GITHUB_SHA:0:7}-${GITHUB_RUN_NUMBER}-${{ matrix.architecture }}" >> $GITHUB_ENV
echo "tag=${GITHUB_REPOSITORY,,}:${{ github.ref_name }}${{ github.event.inputs.tag }}-${GITHUB_SHA:0:7}-${GITHUB_RUN_NUMBER}-${{ matrix.architecture }}" >> $GITHUB_ENV
echo "release=${{ github.event.release.target_commitish }}" >> $GITHUB_ENV
- name: Set up QEMU
@ -77,8 +77,8 @@ jobs:
cache-from: docker.io/${{ env.cache }}
cache-to: docker.io/${{ env.cache }}
tags: |
docker.io/${{ env.tag }}${{ github.event.inputs.tag }}
ghcr.io/${{ env.tag }}${{ github.event.inputs.tag }}
docker.io/${{ env.tag }}
ghcr.io/${{ env.tag }}
labels: |
org.opencontainers.image.created=${{ env.created }}
org.opencontainers.image.title=${{ env.title }}
@ -123,16 +123,13 @@ jobs:
DOCKER_CLI_EXPERIMENTAL: enabled
run: |
IMAGE=${{ matrix.registry }}/${GITHUB_REPOSITORY,,}
TAG=${{ github.ref_name }}
SOURCE=${IMAGE}:${TAG}-${GITHUB_SHA:0:7}-${GITHUB_RUN_NUMBER}${{ github.event.inputs.tag }}
TAG=${{ env.tag }}
VERSION=${{ env.VERSION }}
[[ -f linux-amd64.Dockerfile ]] && AMD64=${SOURCE}-linux-amd64
[[ -f linux-arm64.Dockerfile ]] && ARM64=${SOURCE}-linux-arm64
[[ -f linux-arm-v7.Dockerfile ]] && ARMV7=${SOURCE}-linux-arm-v7
docker manifest create ${IMAGE}:${TAG}${{ github.event.inputs.tag }} ${AMD64} ${ARM64} ${ARMV7}
docker manifest push ${IMAGE}:${TAG}${{ github.event.inputs.tag }}
docker manifest create ${IMAGE}:${TAG}-${GITHUB_SHA:0:7}${{ github.event.inputs.tag }} ${AMD64} ${ARM64} ${ARMV7}
docker manifest push ${IMAGE}:${TAG}-${GITHUB_SHA:0:7}${{ github.event.inputs.tag }}
[[ -f ${{ matrix.architecture }}.Dockerfile ]] && ARCH=${TAG}
docker manifest create ${IMAGE}:${TAG} ${ARCH}
docker manifest push ${IMAGE}:${TAG}
docker manifest create ${IMAGE}:${TAG} ${ARCH}
docker manifest push ${IMAGE}:${TAG}
- name: Latest manifest
if: ${{ github.event.release.target_commitish == 'master' }}
env: