Skip to content

Commit

Permalink
fix goreleaser GHCR login
Browse files Browse the repository at this point in the history
  • Loading branch information
piksel committed Apr 24, 2021
1 parent 692f66b commit ef4873b
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,12 @@ jobs:
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Login to GHCR
uses: docker/login-action@v1
with:
username: ${{ secrets.BOT_USERNAME }}
password: ${{ secrets.BOT_GHCR_PAT }}
registry: ghcr.io
- name: Build
uses: goreleaser/goreleaser-action@v2
with:
Expand Down Expand Up @@ -173,8 +179,11 @@ jobs:
docker manifest push containrrr/watchtower:$(echo $TAG | sed 's/^v*//') && \
docker manifest push containrrr/watchtower:latest
- name: Push manifests to GitHub Container Registry
env:
DOCKER_USER: ${{ secrets.BOT_USERNAME }}
DOCKER_TOKEN: ${{ secrets.BOT_GHCR_PAT }}
run: |
echo "$BOT_GHCR_PAT" | docker login -u $BOT_USERNAME --password-stdin && \
docker login -u $DOCKER_USER -p $DOCKER_TOKEN ghcr.io && \
docker manifest push ghcr.io/containrrr/watchtower:$(echo $TAG | sed 's/^v*//') && \
docker manifest push ghcr.io/containrrr/watchtower:latest
Expand Down

0 comments on commit ef4873b

Please sign in to comment.