Skip to content

Commit

Permalink
fix(ci): latest docker tag targets the latest tag
Browse files Browse the repository at this point in the history
Until now, the latest was more a "dev" release, targeting the latest
changes in the main branch instead of the latest stable release.
  • Loading branch information
bastienwirtz committed Oct 16, 2024
1 parent 6462974 commit b760f04
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 14 deletions.
18 changes: 6 additions & 12 deletions .github/workflows/dockerhub.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
buildkitd-flags: --debug
-
name: Login to Docker Hub
uses: docker/login-action@v2
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
Expand All @@ -36,20 +36,14 @@ jobs:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ github.token }}
-
name: Set tag name
run: |
if [[ ${{ github.ref_type }} == "tag" ]]; then
echo "IMAGE_TAG=${{ github.ref_name }}" >> $GITHUB_ENV
else
echo "IMAGE_TAG=latest" >> $GITHUB_ENV
fi
-
name: Build and push
uses: docker/build-push-action@v5
uses: docker/build-push-action@v6
with:
push: true
tags: |
b4bz/homer:${{env.IMAGE_TAG}}
ghcr.io/${{ github.repository }}:${{ env.IMAGE_TAG }}
b4bz/homer:latest
b4bz/homer:${{ github.ref_name }}
ghcr.io/${{ github.repository }}:latest
ghcr.io/${{ github.repository }}:${{ github.ref_name }}
platforms: linux/amd64,linux/arm/v7,linux/arm/v6,linux/arm64
2 changes: 1 addition & 1 deletion .github/workflows/integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
uses: actions/checkout@v4
-
name: pnpm setup
uses: pnpm/action-setup@v3
uses: pnpm/action-setup@v4
with:
version: 9
-
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
uses: actions/checkout@v4
-
name: pnpm setup
uses: pnpm/action-setup@v3
uses: pnpm/action-setup@v4
with:
version: 9
-
Expand Down

0 comments on commit b760f04

Please sign in to comment.