Skip to content

Commit eafedba

Browse files
committed
GitHub Actions: publish :latest and :latest-debug also to GitHub Container Registry
- DockerHub is ok, but will be ratelimited soon, so this could be a nice alternative
1 parent 8524e37 commit eafedba

File tree

1 file changed

+10
-3
lines changed

1 file changed

+10
-3
lines changed

.github/workflows/master-latest.yaml

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,19 @@ jobs:
2626
restore-keys: |
2727
${{ runner.os }}-buildxarch-
2828
29-
- name: Login to DockerHub
29+
- name: Docker Login to DockerHub
3030
uses: docker/login-action@v1
3131
with:
3232
username: ${{ secrets.DOCKER_HUB_USERNAME }}
3333
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
3434

35+
- name: Docker Login to GitHub Container Registry
36+
uses: docker/login-action@v1
37+
with:
38+
registry: ghcr.io
39+
username: ${{ secrets.DOCKER_GITHUB_USERNAME }}
40+
password: ${{ secrets.DOCKER_GITHUB_PAT }}
41+
3542
# the arm64 is of course much slower due to qemu, so build and push amd64 **first**
3643
# due to the way manifests work, the gap between this and the complete push below
3744
# could result in pull failures or inconsistencies for arm64, such is life.
@@ -46,7 +53,7 @@ jobs:
4653
context: .
4754
file: ./Dockerfile
4855
platforms: linux/amd64
49-
tags: rpardini/docker-registry-proxy:latest
56+
tags: rpardini/docker-registry-proxy:latest,ghcr.io/rpardini/docker-registry-proxy:latest
5057
push: true
5158
cache-from: type=local,src=/tmp/.buildx-cache/release
5259
cache-to: type=local,mode=max,dest=/tmp/.buildx-cache/release
@@ -61,7 +68,7 @@ jobs:
6168
context: .
6269
file: ./Dockerfile
6370
platforms: linux/amd64
64-
tags: rpardini/docker-registry-proxy:latest-debug
71+
tags: rpardini/docker-registry-proxy:latest-debug,ghcr.io/rpardini/docker-registry-proxy:latest-debug
6572
push: true
6673
cache-from: type=local,src=/tmp/.buildx-cache/debug
6774
cache-to: type=local,mode=max,dest=/tmp/.buildx-cache/debug

0 commit comments

Comments
 (0)