From 26a1e4ffda56f3fef8f3a96611072e39cd1fb541 Mon Sep 17 00:00:00 2001 From: Ameer Hamza Date: Wed, 12 Apr 2023 15:56:46 +0800 Subject: [PATCH] Fixed the caching scheme. --- .drone.yml | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/.drone.yml b/.drone.yml index 310ad38..b7f250c 100644 --- a/.drone.yml +++ b/.drone.yml @@ -4,7 +4,7 @@ name: ubuntu steps: - name: create_tags - image: ubuntu:22.04 + image: ubuntu:latest commands: - echo "$(date "+%Y-%m-%d"), latest" > .tags @@ -28,9 +28,9 @@ steps: - linux/arm64 - linux/arm/v7 cache_from: - - type=local\\,src=/cache/${DRONE_REPO}/ubuntu-${UBUNTU_VER} + - type=local\\,src=/cache/${DRONE_REPO}/ubuntu-22.04 cache_to: - - type=local,dest=/cache/${DRONE_REPO}/ubuntu-${UBUNTU_VER},mode=max + - type=local,dest=/cache/${DRONE_REPO}/ubuntu-22.04,mode=max depends_on: - create_tags @@ -43,6 +43,10 @@ steps: repo: ${DRONE_REPO_LINK:8}/ubuntu-20.04 extra_tags: - ${DRONE_REPO_LINK:8}:20.04 + cache_from: + - type=local\\,src=/cache/${DRONE_REPO}/ubuntu-20.04 + cache_to: + - type=local,dest=/cache/${DRONE_REPO}/ubuntu-20.04,mode=max - name: ubuntu_18 image: thegeeklab/drone-docker-buildx:23 @@ -53,3 +57,7 @@ steps: repo: ${DRONE_REPO_LINK:8}/ubuntu-18.04 extra_tags: - ${DRONE_REPO_LINK:8}:18.04 + cache_from: + - type=local\\,src=/cache/${DRONE_REPO}/ubuntu-18.04 + cache_to: + - type=local,dest=/cache/${DRONE_REPO}/ubuntu-18.04,mode=max