Skip to content

Commit

Permalink
Merge pull request #182 from mgxd/ci/clear-cache
Browse files Browse the repository at this point in the history
CI: Reset docker layer caching
  • Loading branch information
djarecka authored Sep 22, 2022
2 parents 901ae72 + 9cc50bd commit f11c9c7
Showing 1 changed file with 25 additions and 8 deletions.
33 changes: 25 additions & 8 deletions .github/workflows/testing.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: CI
name: Build & run notebooks

on:
push:
Expand Down Expand Up @@ -27,33 +27,50 @@ jobs:
# In this step, this action saves a list of existing images,
# the cache is created without them in the post run.
# It also restores the cache if it exists.
- uses: satackey/[email protected]
- uses: satackey/[email protected]
with:
key: tutorial-docker-cache-{hash}
restore-keys: |
tutorial-docker-cache-
layer-tutorial-docker-cache-
- name: build the image
run: docker build . --file Dockerfile -t nipype_tutorial:latest

test_1:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: satackey/[email protected]
- uses: satackey/[email protected]
with:
key: tutorial-docker-cache-{hash}
restore-keys: |
tutorial-docker-cache-
layer-tutorial-docker-cache-
- name: run test 1
run: docker run --rm nipype_tutorial:latest python /home/neuro/nipype_tutorial/test_notebooks.py 1

test_2:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: satackey/[email protected]
- uses: satackey/[email protected]
with:
key: tutorial-docker-cache-{hash}
restore-keys: |
tutorial-docker-cache-
layer-tutorial-docker-cache-
- name: run test 2
run: docker run --rm nipype_tutorial:latest python /home/neuro/nipype_tutorial/test_notebooks.py 2

test_3:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: satackey/[email protected]
- uses: satackey/[email protected]
with:
key: tutorial-docker-cache-{hash}
restore-keys: |
tutorial-docker-cache-
layer-tutorial-docker-cache-
- name: run test 3
run: docker run --rm nipype_tutorial:latest python /home/neuro/nipype_tutorial/test_notebooks.py 3

0 comments on commit f11c9c7

Please sign in to comment.