Debian Codegraph @

.github/workflows/scripts/free-disk-space.sh

raw
1 #!/usr/bin/env bash
2 #
3 # Copyright The OpenTelemetry Authors
4 # SPDX-License-Identifier: Apache-2.0
5
6 echo "Available disk space before:"
7 df -h /
8
9 # The Android SDK is the biggest culprit for the lack of disk space in CI.
10 # It is installed into /usr/local/lib/android manually (ie. not with apt) by this script:
11 # https://github.com/actions/runner-images/blob/main/images/ubuntu/scripts/build/install-android-sdk.sh
12 # so let's delete the directory manually.
13 echo "Deleting unused Android SDK and tools..."
14 sudo rm -rf /usr/local/lib/android
15
16 echo "Available disk space after:"
17 df -h /