Skip to content

Commit

Permalink
feat(workflow): tag release to latest
Browse files Browse the repository at this point in the history
  • Loading branch information
lulu12329 committed Feb 16, 2024
1 parent 141f4f2 commit f459305
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,16 @@ jobs:
[[ "${{ github.ref }}" == "refs/tags/"* ]] && VERSION=$(echo $VERSION | sed -e 's/^v//')
[ "$VERSION" == "master" ] && VERSION=latest
echo IMAGE_ID=$IMAGE_ID
echo VERSION=$VERSION
docker tag $IMAGE_NAME $IMAGE_ID:$VERSION
docker push $IMAGE_ID:$VERSION
if [[ $VERSION =~ ^[0-9]+.[0-9]+.[0-9]+$ ]]; then
docker tag $IMAGE_ID:$VERSION $IMAGE_ID:latest
docker push $IMAGE_ID:$VERSION
fi
# build repoUrl
# change all uppercase characters to lowercase
# strip git ref prefix from version
Expand Down

0 comments on commit f459305

Please sign in to comment.