diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index d99be197..d19682ca 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -57,13 +57,6 @@ jobs: with: username: ${{ secrets.DOCKER_USERNAME }} password: ${{ secrets.DOCKER_PASSWORD }} - - name: Cache Docker layers - uses: actions/cache@v2.1.6 - with: - path: /tmp/.buildx-cache - key: ${{ runner.os }}-buildx-${{ github.sha }} - restore-keys: | - ${{ runner.os }}-buildx- - name: Build and push uses: docker/build-push-action@v2.7.0 with: @@ -72,15 +65,8 @@ jobs: tags: ${{ steps.meta.outputs.tags }} build-args: TAG=${{ steps.meta.outputs.version }} labels: ${{ steps.meta.outputs.labels }} - cache-from: type=local,src=/tmp/.buildx-cache - cache-to: type=local,dest=/tmp/.buildx-cache-new - - # Temp fix - # https://github.com/docker/build-push-action/issues/252 - # https://github.com/moby/buildkit/issues/1896 - name: Move cache - run: | - rm -rf /tmp/.buildx-cache - mv /tmp/.buildx-cache-new /tmp/.buildx-cache + cache-from: type=registry,ref=amir20/dozzle:latest + cache-to: type=inline git-release: needs: [buildx] name: Github Release diff --git a/.github/workflows/dev.yml b/.github/workflows/dev.yml index ffb347f6..9f1104c9 100644 --- a/.github/workflows/dev.yml +++ b/.github/workflows/dev.yml @@ -22,13 +22,6 @@ jobs: with: username: ${{ secrets.DOCKER_USERNAME }} password: ${{ secrets.DOCKER_PASSWORD }} - - name: Cache Docker layers - uses: actions/cache@v2.1.6 - with: - path: /tmp/.buildx-cache - key: ${{ runner.os }}-buildx-${{ github.sha }} - restore-keys: | - ${{ runner.os }}-buildx- - name: Build and push uses: docker/build-push-action@v2.7.0 with: @@ -37,11 +30,8 @@ jobs: tags: ${{ steps.meta.outputs.tags }} build-args: TAG=${{ steps.meta.outputs.version }} labels: ${{ steps.meta.outputs.labels }} - cache-from: type=local,src=/tmp/.buildx-cache - cache-to: type=local,dest=/tmp/.buildx-cache-new - - # Temp fix - # https://github.com/docker/build-push-action/issues/252 - # https://github.com/moby/buildkit/issues/1896 + cache-from: type=registry,ref=amir20/dozzle:master + cache-to: type=inline name: Move cache run: | rm -rf /tmp/.buildx-cache