|
1 | | -name: CI |
| 1 | +name: Build & run notebooks |
2 | 2 |
|
3 | 3 | on: |
4 | 4 | push: |
@@ -27,33 +27,50 @@ jobs: |
27 | 27 | # In this step, this action saves a list of existing images, |
28 | 28 | # the cache is created without them in the post run. |
29 | 29 | # It also restores the cache if it exists. |
30 | | - - uses: satackey/[email protected] |
| 30 | + - uses: satackey/[email protected] |
| 31 | + with: |
| 32 | + key: tutorial-docker-cache-{hash} |
| 33 | + restore-keys: | |
| 34 | + tutorial-docker-cache- |
| 35 | + layer-tutorial-docker-cache- |
31 | 36 | - name: build the image |
32 | 37 | run: docker build . --file Dockerfile -t nipype_tutorial:latest |
33 | 38 |
|
34 | 39 | test_1: |
35 | 40 | needs: build |
36 | 41 | runs-on: ubuntu-latest |
37 | 42 | steps: |
38 | | - - uses: actions/checkout@v2 |
39 | | - - uses: satackey/[email protected] |
| 43 | + - uses: satackey/[email protected] |
| 44 | + with: |
| 45 | + key: tutorial-docker-cache-{hash} |
| 46 | + restore-keys: | |
| 47 | + tutorial-docker-cache- |
| 48 | + layer-tutorial-docker-cache- |
40 | 49 | - name: run test 1 |
41 | 50 | run: docker run --rm nipype_tutorial:latest python /home/neuro/nipype_tutorial/test_notebooks.py 1 |
42 | 51 |
|
43 | 52 | test_2: |
44 | 53 | needs: build |
45 | 54 | runs-on: ubuntu-latest |
46 | 55 | steps: |
47 | | - - uses: actions/checkout@v2 |
48 | | - - uses: satackey/[email protected] |
| 56 | + - uses: satackey/[email protected] |
| 57 | + with: |
| 58 | + key: tutorial-docker-cache-{hash} |
| 59 | + restore-keys: | |
| 60 | + tutorial-docker-cache- |
| 61 | + layer-tutorial-docker-cache- |
49 | 62 | - name: run test 2 |
50 | 63 | run: docker run --rm nipype_tutorial:latest python /home/neuro/nipype_tutorial/test_notebooks.py 2 |
51 | 64 |
|
52 | 65 | test_3: |
53 | 66 | needs: build |
54 | 67 | runs-on: ubuntu-latest |
55 | 68 | steps: |
56 | | - - uses: actions/checkout@v2 |
57 | | - - uses: satackey/[email protected] |
| 69 | + - uses: satackey/[email protected] |
| 70 | + with: |
| 71 | + key: tutorial-docker-cache-{hash} |
| 72 | + restore-keys: | |
| 73 | + tutorial-docker-cache- |
| 74 | + layer-tutorial-docker-cache- |
58 | 75 | - name: run test 3 |
59 | 76 | run: docker run --rm nipype_tutorial:latest python /home/neuro/nipype_tutorial/test_notebooks.py 3 |
0 commit comments