mirror of
https://github.com/sethforprivacy/p2pool-docker.git
synced 2025-12-06 15:52:37 -05:00
Add Docker layer caching
This commit is contained in:
18
.github/workflows/update-base-image.yml
vendored
18
.github/workflows/update-base-image.yml
vendored
@@ -11,6 +11,14 @@ jobs:
|
||||
-
|
||||
name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v1
|
||||
-
|
||||
name: Cache Docker layers
|
||||
uses: actions/cache@v2
|
||||
with:
|
||||
path: /tmp/.buildx-cache
|
||||
key: ${{ runner.os }}-buildx-${{ github.sha }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-buildx-
|
||||
-
|
||||
name: Login to GitHub Container Registry
|
||||
uses: docker/login-action@v1
|
||||
@@ -41,6 +49,16 @@ jobs:
|
||||
ghcr.io/sethsimmons/simple-monerod-docker/simple-monerod:${{ steps.get_tag.outputs.tag }}
|
||||
sethsimmons/simple-monerod:latest
|
||||
sethsimmons/simple-monerod:${{ steps.get_tag.outputs.tag }}
|
||||
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
|
||||
-
|
||||
name: Image digest
|
||||
run: echo ${{ steps.docker_build.outputs.digest }}
|
||||
18
.github/workflows/update-image-on-push.yml
vendored
18
.github/workflows/update-image-on-push.yml
vendored
@@ -12,6 +12,14 @@ jobs:
|
||||
-
|
||||
name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v1
|
||||
-
|
||||
name: Cache Docker layers
|
||||
uses: actions/cache@v2
|
||||
with:
|
||||
path: /tmp/.buildx-cache
|
||||
key: ${{ runner.os }}-buildx-${{ github.sha }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-buildx-
|
||||
-
|
||||
name: Login to GitHub Container Registry
|
||||
uses: docker/login-action@v1
|
||||
@@ -42,6 +50,16 @@ jobs:
|
||||
ghcr.io/sethsimmons/simple-monerod-docker/simple-monerod:${{ steps.get_tag.outputs.tag }}
|
||||
sethsimmons/simple-monerod:latest
|
||||
sethsimmons/simple-monerod:${{ steps.get_tag.outputs.tag }}
|
||||
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
|
||||
-
|
||||
name: Image digest
|
||||
run: echo ${{ steps.docker_build.outputs.digest }}
|
||||
Reference in New Issue
Block a user