Update standard-versioning-for-docker.yaml

This change only allows labeling the container image when there is a release
This commit is contained in:
Yasser Isa 2024-03-07 08:50:56 -07:00 committed by GitHub
parent 25d827af9e
commit 9c7286c976
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 8 deletions

View File

@ -16,12 +16,6 @@ jobs:
steps:
- id: version_step
run: |
if [ "${{ github.ref_name }}" != "" ] && [ "${{ github.ref_name }}" != "main" ]; then
echo "tags=${{ github.ref_name }},${{ github.sha }}" >> $GITHUB_OUTPUT
fi
#if [ "${{ github.ref_name }}" = "main" ]; then
#echo "tags=latest,${{ github.sha }}" >> $GITHUB_OUTPUT
#fi
if [ "${{ github.event_name }}" = "pull_request" ]; then
echo "tags=latest,${{ github.event.pull_request.head.ref }},${{ github.event.pull_request.head.sha }}" >> $GITHUB_OUTPUT
if [ "${{ github.event_name }}" = "release" ]; then
echo "tags=latest,${{ github.event.release.tag_name }}" >> $GITHUB_OUTPUT
fi