Generation de tag

main
stef 2025-12-12 17:50:58 +01:00
parent b3db00f950
commit 685834c5de
1 changed files with 0 additions and 20 deletions

View File

@ -41,26 +41,6 @@ jobs:
echo "All env variables:"
env | grep -i gitea
- name: Generate Docker tags from Gitea context
id: docker_tags
run: |
# Récupérer le SHA court du commit
SHORT_SHA=$(git rev-parse --short HEAD)
# Pour les tags Git (si l'événement est un tag)
if [[ "${GITEA_REF}" == refs/tags/* ]]; then
TAG_NAME=${GITEA_REF#refs/tags/}
echo "TAGS=gitea.bv.stef.lan/stef/pki-manager:${TAG_NAME}" >> $GITHUB_OUTPUT
echo "TAGS=gitea.bv.stef.lan/stef/pki-manager:latest" >> $GITHUB_OUTPUT
else
# Pour les commits normaux
echo "TAGS=gitea.bv.stef.lan/stef/pki-manager:${SHORT_SHA}" >> $GITHUB_OUTPUT
echo "TAGS=gitea.bv.stef.lan/stef/pki-manager:latest" >> $GITHUB_OUTPUT
fi
echo "Generated tags will be:"
echo "${{ steps.docker_tags.outputs.TAGS }}"
- name: Build and push image
uses: docker/build-push-action@v6
with: