From 4b757a38ed60770d0388dc40183e959350c2a9cb Mon Sep 17 00:00:00 2001 From: Tom Aarsen Date: Fri, 23 Aug 2024 11:26:33 +0200 Subject: [PATCH] Attempt to delete unnecessary files from the runner image on Linux --- .github/workflows/tests.yml | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 0ef8adcc7..aa3afc3c2 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -22,6 +22,26 @@ jobs: fail-fast: false runs-on: ${{ matrix.os }} steps: + - name: Remove unnecessary files + run: | + # Remove software and language runtimes we're not using + sudo rm -rf \ + "$AGENT_TOOLSDIRECTORY" \ + /opt/google/chrome \ + /opt/microsoft/msedge \ + /opt/microsoft/powershell \ + /opt/pipx \ + /usr/lib/mono \ + /usr/local/julia* \ + /usr/local/lib/android \ + /usr/local/lib/node_modules \ + /usr/local/share/chromium \ + /usr/local/share/powershell \ + /usr/share/dotnet \ + /usr/share/swift + df -h / + if: runner.os == 'Linux' + - name: Checkout code uses: actions/checkout@v3