From 269c5f58774fffcfe60885833db1088b353ba212 Mon Sep 17 00:00:00 2001 From: Jeremi Piotrowski Date: Fri, 3 Mar 2023 11:35:24 +0100 Subject: [PATCH] workflows: static-checks: Free disk space before running checks We've been seeing the 'sudo make test' job occasionally run out of space in /tmp, which is part of the root filesystem. Removing dotnet and `AGENT_TOOLSDIRECTORY` frees around 10GB of space and in my tests the job still has 13GB of space left after running. Fixes: #6401 Signed-off-by: Jeremi Piotrowski --- .github/workflows/static-checks.yaml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/static-checks.yaml b/.github/workflows/static-checks.yaml index 76310f2426..616e9f5abf 100644 --- a/.github/workflows/static-checks.yaml +++ b/.github/workflows/static-checks.yaml @@ -23,6 +23,10 @@ jobs: target_branch: ${{ github.base_ref }} GOPATH: ${{ github.workspace }} steps: + - name: Free disk space + run: | + sudo rm -rf /usr/share/dotnet + sudo rm -rf "$AGENT_TOOLSDIRECTORY" - name: Checkout code uses: actions/checkout@v3 with: