diff --git a/.github/actions/free-disk-space/action.yml b/.github/actions/free-disk-space/action.yml index 1eb453fa6e..17164d82fb 100644 --- a/.github/actions/free-disk-space/action.yml +++ b/.github/actions/free-disk-space/action.yml @@ -13,5 +13,8 @@ runs: sudo rm -rf /usr/share/az_* sudo rm -rf /opt/az sudo rm -rf /usr/lib/google-cloud-sdk + sudo rm -rf /opt/ghc + sudo rm -rf "/usr/local/share/boost" + sudo rm -rf "$AGENT_TOOLSDIRECTORY" echo "Disk space after cleanup:" df -h diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 260c59e71b..c57e37f938 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -612,16 +612,13 @@ jobs: timeout-minutes: 60 steps: # https://github.com/actions/runner-images/issues/2840#issuecomment-790492173 - - name: Free disk space - run: | - echo "Disk space before cleanup:" - df -h - sudo rm -rf /usr/share/dotnet - sudo rm -rf /opt/ghc - sudo rm -rf "/usr/local/share/boost" - sudo rm -rf "$AGENT_TOOLSDIRECTORY" - echo "Disk space after cleanup:" - df -h + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + filter: tree:0 + submodules: recursive + - name: Free space + uses: ./.github/actions/free-disk-space - name: Set up QEMU uses: docker/setup-qemu-action@v3 - name: Configure docker @@ -633,11 +630,6 @@ jobs: "containerd-snapshotter": true } } - - uses: actions/checkout@v4 - with: - fetch-depth: 0 - filter: tree:0 - submodules: recursive - name: Checkout init repository run: |