From b8d25bd2cdea0bde053d9895bff53b8564ebcac9 Mon Sep 17 00:00:00 2001 From: Chris Evich Date: Fri, 13 Nov 2020 10:49:07 -0500 Subject: Cirrus: Invalidate static cache on VM image update It's important to periodically update the nix cache (about 1GB in size). If not, it can grow stale and has been observed causing task failures. Associating the nix cache update with a VM/Container image update, ensures it happens first in PRs where environment-related failures are less surprising. Signed-off-by: Chris Evich --- .cirrus.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to '.cirrus.yml') diff --git a/.cirrus.yml b/.cirrus.yml index 4156e3082..5f99b0490 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -362,7 +362,8 @@ static_alt_build_task: # this cache ensures only the static podman binary is built. nix_cache: folder: '/var/cache/nix' - fingerprint_script: cat nix/* + # Cirrus will calculate/use sha of this output as the cache key + fingerprint_script: echo "${IMAGE_SUFFIX}" && cat nix/* setup_script: *setup main_script: *main always: *binary_artifacts -- cgit v1.2.3-54-g00ecf