ci: use CACHE_NAME in main.yml

This commit is contained in:
Geoff Bourne 2021-05-21 17:04:11 -05:00
parent 9bd6bc64b0
commit c9815e2ccb
2 changed files with 5 additions and 2 deletions

View File

@ -49,6 +49,7 @@ jobs:
key: ${{ runner.os }}-buildx-${{ env.CACHE_NAME }}-${{ github.sha }}
restore-keys: |
${{ runner.os }}-buildx-${{ env.CACHE_NAME }}-
${{ runner.os }}-buildx-
- name: Set up QEMU
uses: docker/setup-qemu-action@v1.1.0

View File

@ -29,6 +29,8 @@ jobs:
needs:
- test
runs-on: ubuntu-20.04
env:
CACHE_NAME: master
steps:
- uses: actions/checkout@v2.3.4
@ -60,9 +62,9 @@ jobs:
uses: actions/cache@v2.1.5
with:
path: /tmp/.buildx-cache
key: ${{ runner.os }}-buildx-${{ steps.prep.outputs.cache_version }}-${{ github.sha }}
key: ${{ runner.os }}-buildx-${{ env.CACHE_NAME }}-${{ github.sha }}
restore-keys: |
${{ runner.os }}-buildx-${{ steps.prep.outputs.cache_version }}-
${{ runner.os }}-buildx-${{ env.CACHE_NAME }}-
${{ runner.os }}-buildx-
- name: Login to DockerHub