feat: add cache to drone CD

main
Lucien Cartier-Tilet 2023-03-26 16:28:26 +02:00
parent d6c9245ed5
commit 76ba1e3f30
Signed by: phundrak
GPG Key ID: BD7789E705CB8DCA
1 changed files with 26 additions and 0 deletions

View File

@ -4,8 +4,20 @@ type: docker
name: CI
steps:
- name: restore docker cache
image: drillster/drone-volume-cache
volumes:
- name: pleroma-docker
path: /cache/pleroma/docker
settings:
restore: true
mount:
- /var/cache/pleroma-drone-build
- name: docker
image: plugins/docker
depends_on:
- "restore docker cache"
settings:
username: phundrak
password:
@ -19,4 +31,18 @@ steps:
--pull
--platform amd64
--tag "phundrak/pleroma:latest"
--cache-from type=local,dest=/var/cache/pleroma-drone-build
--cache-to type=local,dest=/var/cache/pleroma-drone-build
)
- name: rebuild cache docker
image: drillster/drone-volume-cache
depends_on:
- "docker"
volumes:
- name: pleroma-docker
path: /cache/pleroma/docker
settings:
rebuild: true
mount:
- /var/cache/pleroma-drone-build