fix: two tag extensions

Run docker build -t
ghcr.io/ghcr.io/jgsuess/fhirflare-ig-toolkit:main:latest .
ERROR: failed to build: invalid tag
"ghcr.io/ghcr.io/jgsuess/fhirflare-ig-toolkit:main:latest": invalid
reference format
This commit is contained in:
Jörn Guy Süß 2025-07-15 10:21:03 +10:00
parent 6ede139084
commit e2a6b19a2e

View File

@ -38,12 +38,16 @@ jobs:
- name: Set normalized image name
run: |
echo "IMAGE_NAME=${{ steps.meta.outputs.tags }}" >> $GITHUB_ENV
if [[ "${{ github.ref_name }}" == "main" ]]; then
echo "IMAGE_NAME=$(echo ${{ steps.meta.outputs.tags }} | sed 's/:main/:latest/')" >> $GITHUB_ENV
else
echo "IMAGE_NAME=${{ steps.meta.outputs.tags }}" >> $GITHUB_ENV
fi
- name: Build Docker image
run: |
docker build -t ghcr.io/${{ env.IMAGE_NAME }}:latest .
docker build -t ${{ env.IMAGE_NAME }} .
- name: Push Docker image
run: |
docker push ghcr.io/${{ env.IMAGE_NAME }}:latest
docker push ${{ env.IMAGE_NAME }}