mirror of
https://github.com/dani-garcia/vaultwarden.git
synced 2025-12-13 14:02:34 +02:00
Fix release workflow (#6532)
This commit is contained in:
committed by
GitHub
parent
4ad8baf7be
commit
9cca120fb3
21
.github/workflows/release.yml
vendored
21
.github/workflows/release.yml
vendored
@@ -363,6 +363,7 @@ jobs:
|
|||||||
working-directory: ${{ runner.temp }}/digests
|
working-directory: ${{ runner.temp }}/digests
|
||||||
env:
|
env:
|
||||||
BASE_IMAGE: "${{ matrix.base_image }}"
|
BASE_IMAGE: "${{ matrix.base_image }}"
|
||||||
|
BASE_IMAGE_TAG: "${{ matrix.base_image == 'debian' && '' || format('-{0}', matrix.base_image) }}"
|
||||||
BASE_TAGS: "${{ env.BASE_TAGS }}"
|
BASE_TAGS: "${{ env.BASE_TAGS }}"
|
||||||
CONTAINER_REGISTRIES: "${{ env.CONTAINER_REGISTRIES }}"
|
CONTAINER_REGISTRIES: "${{ env.CONTAINER_REGISTRIES }}"
|
||||||
run: |
|
run: |
|
||||||
@@ -371,27 +372,27 @@ jobs:
|
|||||||
IFS=',' read -ra TAGS <<< "${BASE_TAGS}"
|
IFS=',' read -ra TAGS <<< "${BASE_TAGS}"
|
||||||
for img in "${IMAGES[@]}"; do
|
for img in "${IMAGES[@]}"; do
|
||||||
for tag in "${TAGS[@]}"; do
|
for tag in "${TAGS[@]}"; do
|
||||||
echo "Creating manifest for $img:$tag-${BASE_IMAGE}"
|
echo "Creating manifest for ${img}:${tag}${BASE_IMAGE_TAG}"
|
||||||
|
|
||||||
OUTPUT=$(docker buildx imagetools create \
|
OUTPUT=$(docker buildx imagetools create \
|
||||||
-t "$img:$tag-${BASE_IMAGE}" \
|
-t "${img}:${tag}${BASE_IMAGE_TAG}" \
|
||||||
$(printf "$img:$tag-${BASE_IMAGE}@sha256:%s " *) 2>&1)
|
$(printf "${img}:${tag}-${BASE_IMAGE}@sha256:%s " *) 2>&1)
|
||||||
STATUS=$?
|
STATUS=$?
|
||||||
|
|
||||||
if [ $STATUS -ne 0 ]; then
|
if [ ${STATUS} -ne 0 ]; then
|
||||||
echo "Manifest creation failed for $img"
|
echo "Manifest creation failed for ${img}"
|
||||||
echo "$OUTPUT"
|
echo "${OUTPUT}"
|
||||||
exit $STATUS
|
exit ${STATUS}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "Manifest created for $img"
|
echo "Manifest created for ${img}"
|
||||||
echo "$OUTPUT"
|
echo "${OUTPUT}"
|
||||||
done
|
done
|
||||||
done
|
done
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
# Extract digest SHA for subsequent steps
|
# Extract digest SHA for subsequent steps
|
||||||
GET_DIGEST_SHA="$(echo "$OUTPUT" | grep -oE 'sha256:[a-f0-9]{64}' | tail -1)"
|
GET_DIGEST_SHA="$(echo "${OUTPUT}" | grep -oE 'sha256:[a-f0-9]{64}' | tail -1)"
|
||||||
echo "DIGEST_SHA=${GET_DIGEST_SHA}" | tee -a "${GITHUB_ENV}"
|
echo "DIGEST_SHA=${GET_DIGEST_SHA}" | tee -a "${GITHUB_ENV}"
|
||||||
|
|
||||||
# Attest container images
|
# Attest container images
|
||||||
|
|||||||
Reference in New Issue
Block a user