From 2abb8333f1606009648fee938142f2eb111f4893 Mon Sep 17 00:00:00 2001 From: jolov Date: Fri, 17 Apr 2026 08:34:15 -0700 Subject: [PATCH] fix: redirect caches to Agent.TempDirectory to avoid disk space issues The CreateAzureSdkForNetPR stage was running out of disk space (95%+) during generation. Redirect NUGET_PACKAGES, npm_config_cache, and TMPDIR to Agent.TempDirectory which is on a separate, larger partition on Azure DevOps hosted agents. Also limit artifact download to only build_artifacts_csharp instead of downloading all pipeline artifacts. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- packages/http-client-csharp/eng/pipeline/publish.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/packages/http-client-csharp/eng/pipeline/publish.yml b/packages/http-client-csharp/eng/pipeline/publish.yml index 9e953867b38..fd1cf5ace9e 100644 --- a/packages/http-client-csharp/eng/pipeline/publish.yml +++ b/packages/http-client-csharp/eng/pipeline/publish.yml @@ -106,6 +106,12 @@ extends: jobs: - job: CreatePR timeoutInMinutes: 90 + variables: + # Redirect temp and cache directories to Agent.TempDirectory (a separate, larger partition) + # to avoid running out of disk space on the root partition during generation + TMPDIR: $(Agent.TempDirectory) + NUGET_PACKAGES: $(Agent.TempDirectory)/nuget + npm_config_cache: $(Agent.TempDirectory)/npm-cache steps: - checkout: self - pwsh: | @@ -150,6 +156,7 @@ extends: workingFile: $(Build.SourcesDirectory)/packages/http-client-csharp/.npmrc - download: current + artifact: build_artifacts_csharp displayName: Download pipeline artifacts - pwsh: |