From 678a99879c7f94c80773e52b6b9fd37d4f3b63f3 Mon Sep 17 00:00:00 2001 From: Nick Dumas Date: Wed, 3 Jul 2024 11:24:24 -0400 Subject: [PATCH] I'm finally seeing the light --- .drone.yml | 37 +++++++++---------------------------- build.sh | 2 +- 2 files changed, 10 insertions(+), 29 deletions(-) diff --git a/.drone.yml b/.drone.yml index f2e6fe2..925d0f1 100644 --- a/.drone.yml +++ b/.drone.yml @@ -6,18 +6,7 @@ clone: depth: 1 steps: -- name: restore_cache - image: drillster/drone-volume-cache - volumes: - - name: go_module_cache - path: /var/cache/go/hugo_cache/ - settings: - restore: true - mount: - - /drone/src/hugo_cache/ - name: hugo_prod - depends_on: - - restore_cache image: code.ndumas.com/ndumas/hugo:latest commands: - hugo --enableGitInfo -d /drone/src/public/ --baseURL https://blog.ndumas.com @@ -25,9 +14,10 @@ steps: branch: include: - main + volumes: + - name: go_module_cache + path: /tmp/hugo_cache/ - name: hugo_dev - depends_on: - - restore_cache image: code.ndumas.com/ndumas/hugo commands: - hugo --enableGitInfo -d /drone/src/public/ --baseURL https://dev.blog.ndumas.com @@ -35,9 +25,10 @@ steps: branch: include: - dev + volumes: + - name: go_module_cache + path: /tmp/hugo_cache/ - name: hugo_drafts - depends_on: - - restore_cache image: code.ndumas.com/ndumas/hugo commands: - hugo --enableGitInfo -DF -d /drone/src/public/ --baseURL https://drafts.blog.ndumas.com @@ -45,6 +36,9 @@ steps: branch: include: - drafts + volumes: + - name: go_module_cache + path: /tmp/hugo_cache/ - name: publish_prod depends_on: - hugo_prod @@ -99,19 +93,6 @@ steps: branch: include: - drafts -- name: rebuild_cache - depends_on: - - publish_prod - - publish_dev - - publish_drafts - image: drillster/drone-volume-cache - volumes: - - name: go_module_cache - path: /var/cache/go/hugo_cache/ - settings: - rebuild: true - mount: - - /drone/src/hugo_cache/ volumes: - name: go_module_cache host: diff --git a/build.sh b/build.sh index fdf34f8..28ecb30 100755 --- a/build.sh +++ b/build.sh @@ -1,6 +1,6 @@ #! /bin/bash -export HUGO_CACHEDIR="/drone/src/hugo_cache/" +export HUGO_CACHEDIR="/tmp/hugo_cache/" # debug alias # alias hugo=hugo -v --debug --logLevel=debug --printI18nWarnings --printPathWarnings --printUnusedTemplates --templateMetrics --templateMetricsHints