Skip to content

High performance self-hosted photo and video management solution.

ci: copy image layers from ghcr to dockerhub on release (#16155)

Zack Pollard924d11a91364
diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml
index c31a9a5257..394da6e1a0 100644
--- a/.github/workflows/docker.yml
+++ b/.github/workflows/docker.yml
@@ -101,7 +101,6 @@ jobs:
context: machine-learning
file: machine-learning/Dockerfile
GHCR_REPO: ghcr.io/${{ github.repository_owner }}/immich-machine-learning
- DOCKER_REPO: altran1502/immich-machine-learning
strategy:
# Prevent a failure in one image from stopping the other builds
fail-fast: false
@@ -142,14 +141,6 @@ jobs:
- name: Set up Docker Buildx
uses: docker/[email protected]
- - name: Login to Docker Hub
- # Only push to Docker Hub when making a release
- if: ${{ !github.event.pull_request.head.repo.fork }}
- uses: docker/login-action@v3
- with:
- username: ${{ secrets.DOCKERHUB_USERNAME }}
- password: ${{ secrets.DOCKERHUB_TOKEN }}
-
- name: Login to GitHub Container Registry
uses: docker/login-action@v3
# Skip when PR from a fork
@@ -169,7 +160,7 @@ jobs:
# Skip pushing when PR from a fork
push: ${{ !github.event.pull_request.head.repo.fork }}
labels: ${{ steps.metadata.outputs.labels }}
- outputs: type=image,"name=${{ env.GHCR_REPO }},${{ env.DOCKER_REPO }}",push-by-digest=true,name-canonical=true,push=true
+ outputs: type=image,"name=${{ env.GHCR_REPO }}",push-by-digest=true,name-canonical=true,push=true
build-args: |
DEVICE=${{ matrix.device }}
BUILD_ID=${{ github.run_id }}
@@ -260,8 +251,7 @@ jobs:
working-directory: ${{ runner.temp }}/digests
run: |
docker buildx imagetools create $(jq -cr '.tags | map("-t " + .) | join(" ")' <<< "$DOCKER_METADATA_OUTPUT_JSON") \
- $(printf '${{ env.GHCR_REPO }}@sha256:%s ' *) \
- $(printf '${{ env.DOCKER_REPO }}@sha256:%s ' *)
+ $(printf '${{ env.GHCR_REPO }}@sha256:%s ' *)
build_and_push_server:
name: Build and Push Server
@@ -273,7 +263,6 @@ jobs:
context: .
file: server/Dockerfile
GHCR_REPO: ghcr.io/${{ github.repository_owner }}/immich-server
- DOCKER_REPO: altran1502/immich-server
strategy:
fail-fast: false
matrix:
@@ -294,13 +283,6 @@ jobs:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- - name: Login to Docker Hub
- uses: docker/login-action@v3
- if: ${{ !github.event.pull_request.head.repo.fork }}
- with:
- username: ${{ secrets.DOCKERHUB_USERNAME }}
- password: ${{ secrets.DOCKERHUB_TOKEN }}
-
- name: Login to GitHub Container Registry
uses: docker/login-action@v3
# Skip when PR from a fork
@@ -320,7 +302,7 @@ jobs:
# Skip pushing when PR from a fork
push: ${{ !github.event.pull_request.head.repo.fork }}
labels: ${{ steps.metadata.outputs.labels }}
- outputs: type=image,"name=${{ env.GHCR_REPO }},${{ env.DOCKER_REPO }}",push-by-digest=true,name-canonical=true,push=true
+ outputs: type=image,"name=${{ env.GHCR_REPO }}",push-by-digest=true,name-canonical=true,push=true
build-args: |
DEVICE=cpu
BUILD_ID=${{ github.run_id }}
@@ -401,8 +383,7 @@ jobs:
working-directory: ${{ runner.temp }}/digests
run: |
docker buildx imagetools create $(jq -cr '.tags | map("-t " + .) | join(" ")' <<< "$DOCKER_METADATA_OUTPUT_JSON") \
- $(printf '${{ env.GHCR_REPO }}@sha256:%s ' *) \
- $(printf '${{ env.DOCKER_REPO }}@sha256:%s ' *)
+ $(printf '${{ env.GHCR_REPO }}@sha256:%s ' *)
success-check-server:
name: Docker Build & Push Server Success