From 906525a84f051f398f99313fc185ab826ef445c6 Mon Sep 17 00:00:00 2001 From: luke-lombardi <33990301+luke-lombardi@users.noreply.github.com> Date: Thu, 19 Dec 2024 23:03:01 -0500 Subject: [PATCH] fix: Don't volume cache builds (#803) --- pkg/worker/lifecycle.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/worker/lifecycle.go b/pkg/worker/lifecycle.go index 4099212eb..1b500c182 100644 --- a/pkg/worker/lifecycle.go +++ b/pkg/worker/lifecycle.go @@ -367,7 +367,7 @@ func (s *Worker) specFromRequest(request *types.ContainerRequest, options *Conta } // If volume caching is enabled, set it up and add proper mounts to spec - if s.fileCacheManager.CacheAvailable() && request.Workspace.VolumeCacheEnabled { + if s.fileCacheManager.CacheAvailable() && request.Workspace.VolumeCacheEnabled && !request.IsBuildRequest() { err = s.fileCacheManager.EnableVolumeCaching(request.Workspace.Name, volumeCacheMap, spec) if err != nil { log.Error().Str("container_id", request.ContainerId).Msgf("failed to setup volume caching: %v", err)