From 59f8a16f0f73b9e985b125baea65e848b7909553 Mon Sep 17 00:00:00 2001 From: Gregory Giguashvili Date: Tue, 21 Oct 2025 09:12:00 +0300 Subject: [PATCH] Best effort attempt to clean /mnt partition --- .github/actions/prebuild/action.yaml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/actions/prebuild/action.yaml b/.github/actions/prebuild/action.yaml index aba521ea..ffb52c8a 100644 --- a/.github/actions/prebuild/action.yaml +++ b/.github/actions/prebuild/action.yaml @@ -10,10 +10,16 @@ runs: set -euo pipefail set -x - # The /dev/sdb1 partition is mounted as /mnt. + # Attempt to clean up any pre-existing files on the /mnt partition to + # conserve disk space. Note that this is a best-effort approach and + # not all files may be removed (e.g. swapfile, etc.). + sudo rm -rvf /mnt/* || true + + # Create the necessary directories on the /mnt partition sudo mkdir -p /mnt/tmp /mnt/rpms /mnt/release sudo chmod 1777 /mnt/tmp + # Install the pre-requisites for the build and run environment sudo apt-get update -y -q sudo apt-get install -y -q make lvm2 podman jq curl alien