Use cache for deploy as well
@@ -20,8 +20,22 @@ jobs:
${{ runner.OS }}-build-${{ env.cache-name }}-
${{ runner.OS }}-build-
${{ runner.OS }}-
- - name: Test
- run: make ci
+ - run: make envvar
+
+ # Pull the latest image to build, and avoid caching pull-only images.
+ # (docker pull is faster than caching in most cases.)
+ - run: docker-compose pull
+
+ # 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/action-docker-layer-caching@v0.0.8
+ # Ignore the failure of a step and avoid terminating the job.
+ continue-on-error: true
+
+ - run: make image
+
+ - run: make test
deploy:
name: Deploy
