1
Fork 0

Rollup merge of #69252 - Mark-Simulacrum:disk-try, r=pietroalbini

Clean out unused directories for extra disk space

This cleans out some of the unused (but large) directories on our linux builders to hopefully allow them to complete without running out of disk space.
This commit is contained in:
Yuki Okushi 2020-02-18 20:09:11 +09:00 committed by GitHub
commit c1a05fbf00
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 19 additions and 0 deletions

View file

@ -31,6 +31,9 @@ steps:
- bash: src/ci/scripts/setup-environment.sh
displayName: Setup environment
- bash: src/ci/scripts/clean-disk.sh
displayName: Clean disk
- bash: src/ci/scripts/should-skip-this.sh
displayName: Decide whether to run this job

16
src/ci/scripts/clean-disk.sh Executable file
View file

@ -0,0 +1,16 @@
#!/bin/bash
# This script deletes some of the Azure-provided artifacts. We don't use these,
# and disk space is at a premium on our builders.
set -euo pipefail
IFS=$'\n\t'
source "$(cd "$(dirname "$0")" && pwd)/../shared.sh"
# All the Linux builds happen inside Docker.
if isLinux; then
# 6.7GB
sudo rm -rf /opt/ghc
# 16GB
sudo rm -rf /usr/share/dotnet
fi