ci: Speed up build with cache
Some checks reported errors
continuous-integration/drone/push Build was killed

This commit is contained in:
Glenn Y. Rolland 2022-08-19 11:36:24 +02:00
parent 679529b5b5
commit 758a535320

View file

@ -17,13 +17,13 @@ steps:
commands:
# Debug
- pwd
- mkdir -p _artifacts
- mkdir -p _artifacts _cache
- name: "build:executable"
image: crystallang/crystal:1.5.0
volumes:
- name: cache
path: /stupid
- name: crystal_cache
path: /drone/src/_cache
commands:
# Debug
- pwd
@ -37,15 +37,21 @@ steps:
volumes:
- name: dockersock
path: /var/run
- name: cache
path: /stupid
- name: docker_cache
path: /drone/src/_cache
commands:
# Prepare
- apk add make
- test -f _cache/docker-image.tar && docker load < _cache/docker-image.tar
# Build
- make docker-build
- make docker-save > _artifacts/docker-image.tar
- make docker-save > _cache/docker-image.tar
volumes:
- name: cache
- name: crystal_cache
temp: {}
- name: docker_cache
temp: {}
- name: dockersock
temp: {}