mirror of
https://github.com/datarhei/core.git
synced 2025-09-27 12:22:28 +08:00
Reset layer cache experiments
This commit is contained in:
20
.github/workflows/build_base_vod.yaml
vendored
20
.github/workflows/build_base_vod.yaml
vendored
@@ -7,9 +7,6 @@ on:
|
|||||||
branches:
|
branches:
|
||||||
- vod
|
- vod
|
||||||
|
|
||||||
env:
|
|
||||||
cachedir: /tmp/.buildx-cache-core-vod
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
docker:
|
docker:
|
||||||
runs-on: [self-hosted]
|
runs-on: [self-hosted]
|
||||||
@@ -56,8 +53,10 @@ jobs:
|
|||||||
- name: Cache Docker layers
|
- name: Cache Docker layers
|
||||||
uses: actions/cache@v4
|
uses: actions/cache@v4
|
||||||
with:
|
with:
|
||||||
path: ${{ env.cachedir }}-${{ matrix.key }}
|
path: /tmp/.buildx-cache
|
||||||
key: ${{ runner.os }}-buildx-${{ github.sha }}-${{ matrix.key }}
|
key: ${{ runner.os }}-buildx-${{ github.sha }}
|
||||||
|
restore-keys: |
|
||||||
|
${{ runner.os }}-buildx-
|
||||||
|
|
||||||
- name: Login to DockerHub
|
- name: Login to DockerHub
|
||||||
if: github.event_name != 'pull_request'
|
if: github.event_name != 'pull_request'
|
||||||
@@ -79,12 +78,5 @@ jobs:
|
|||||||
push: true
|
push: true
|
||||||
tags: ${{ steps.meta.outputs.tags }}
|
tags: ${{ steps.meta.outputs.tags }}
|
||||||
labels: ${{ steps.meta.outputs.labels }}
|
labels: ${{ steps.meta.outputs.labels }}
|
||||||
cache-from: type=local,src=${{ env.cachedir }}-${{ matrix.key }}
|
cache-from: type=local,src=/tmp/.buildx-cache
|
||||||
cache-to: type=local,dest=${{ env.cachedir }}-${{ matrix.key }}-new,mode=max
|
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 ${{ env.cachedir }}-${{ matrix.key }}
|
|
||||||
mv ${{ env.cachedir }}-${{ matrix.key }}-new ${{ env.cachedir }}-${{ matrix.key }}
|
|
||||||
|
Reference in New Issue
Block a user