From bcc71175a50b333bfd161aadec1519c977b0a680 Mon Sep 17 00:00:00 2001 From: Thomas Rogers Date: Thu, 30 Jan 2025 15:52:16 +0100 Subject: [PATCH] Fix cache? --- .../build-self-host-docker-images.yml | 38 ++++++++++--------- 1 file changed, 20 insertions(+), 18 deletions(-) diff --git a/.github/workflows/build-self-host-docker-images.yml b/.github/workflows/build-self-host-docker-images.yml index 2aa58b859..ce7cac84a 100644 --- a/.github/workflows/build-self-host-docker-images.yml +++ b/.github/workflows/build-self-host-docker-images.yml @@ -35,6 +35,26 @@ jobs: - name: Set up Docker Buildx uses: docker/setup-buildx-action@v3 + - name: Build and push backend + uses: docker/build-push-action@v6 + with: + platforms: linux/amd64,linux/arm64 + push: true + tags: ghcr.io/omnivore-app/sh-backend:latest,ghcr.io/omnivore-app/sh-backend:${{ github.sha }} + file: packages/api/Dockerfile + cache-from: type=registry,ref=ghcr.io/omnivore-app/sh-backend:latest + cache-to: type=registry,ref=ghcr.io/omnivore-app/sh-backend:latest,mode=max + + - name: Build and push queue-processor + uses: docker/build-push-action@v6 + with: + platforms: linux/amd64,linux/arm64 + push: true + tags: ghcr.io/omnivore-app/sh-queue-processor:latest,ghcr.io/omnivore-app/sh-queue-processor:${{ github.sha }} + file: packages/api/queue-processor/Dockerfile + cache-from: type=registry,ref=ghcr.io/omnivore-app/queue-processor:latest + cache-to: type=registry,ref=ghcr.io/omnivore-app/queue-processor:latest,mode=max + - name: Build and push image-proxy uses: docker/build-push-action@v6 with: @@ -76,22 +96,4 @@ jobs: cache-from: type=registry,ref=ghcr.io/omnivore-app/sh-local-mail-watcher:latest cache-to: type=registry,ref=ghcr.io/omnivore-app/sh-local-mail-watcher:latest,mode=max - - name: Build and push backend - uses: docker/build-push-action@v6 - with: - platforms: linux/amd64,linux/arm64 - push: true - tags: ghcr.io/omnivore-app/sh-backend:latest,ghcr.io/omnivore-app/sh-backend:${{ github.sha }} - file: packages/api/Dockerfile - cache-from: type=registry,ref=ghcr.io/omnivore-app/sh-backend:latest - cache-to: type=registry,ref=ghcr.io/omnivore-app/sh-backend:latest,mode=max - - name: Build and push queue-processor - uses: docker/build-push-action@v6 - with: - platforms: linux/amd64,linux/arm64 - push: true - tags: ghcr.io/omnivore-app/sh-queue-processor:latest,ghcr.io/omnivore-app/sh-queue-processor:${{ github.sha }} - file: packages/api/queue-processor/Dockerfile - cache-from: type=registry,ref=ghcr.io/omnivore-app/queue-processor:latest - cache-to: type=registry,ref=ghcr.io/omnivore-app/queue-processor:latest,mode=max