ci: fix python packages caching (#1893)

This commit is contained in:
Jonas L 2022-06-18 15:54:16 +02:00 committed by GitHub
parent b10696265f
commit 50877a033b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 6 deletions

View File

@ -57,7 +57,9 @@ jobs:
- focal
- jammy
container: ghcr.io/libretime/libretime-dev:${{ matrix.release }}
container:
image: ghcr.io/libretime/libretime-dev:${{ matrix.release }}
options: --user 1001
defaults:
run:
shell: bash
@ -68,9 +70,9 @@ jobs:
- uses: actions/cache@v3
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ inputs.context }}-${{ hashFiles(format('{0}/{1}', inputs.context, '**/setup.py')) }}
key: ${{ matrix.release }}-pip-${{ inputs.context }}-${{ hashFiles(format('{0}/{1}', inputs.context, '**/setup.py')) }}
restore-keys: |
${{ runner.os }}-pip-${{ inputs.context }}
${{ matrix.release }}-pip-${{ inputs.context }}
- name: Test
run: make test

View File

@ -46,7 +46,9 @@ jobs:
--health-timeout 5s
--health-retries 5
container: ghcr.io/libretime/libretime-dev:${{ matrix.release }}
container:
image: ghcr.io/libretime/libretime-dev:${{ matrix.release }}
options: --user 1001
defaults:
run:
shell: bash
@ -59,9 +61,9 @@ jobs:
- uses: actions/cache@v3
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-api-${{ hashFiles('api/**/setup.py') }}
key: ${{ matrix.release }}-pip-api-${{ hashFiles('api/**/setup.py') }}
restore-keys: |
${{ runner.os }}-pip-api
${{ matrix.release }}-pip-api
- name: Test
run: make test