From f75296e8fac7cb073b89a1508d058be4eb02c742 Mon Sep 17 00:00:00 2001 From: Artyom Savchenko Date: Tue, 18 Nov 2025 14:54:43 +0700 Subject: [PATCH] Free disk space for ui tests (#10225) * Free disk space for ui tests Signed-off-by: Artem Savchenko * Rollback space free Signed-off-by: Artem Savchenko * Add free space action Signed-off-by: Artem Savchenko * Remove temp Signed-off-by: Artem Savchenko * Fix free space Signed-off-by: Artem Savchenko * Add space check Signed-off-by: Artem Savchenko * Free temp only Signed-off-by: Artem Savchenko * Check root space Signed-off-by: Artem Savchenko * Extened cleanup Signed-off-by: Artem Savchenko * Do not remove temp Signed-off-by: Artem Savchenko --------- Signed-off-by: Artem Savchenko --- .github/actions/free-disk-space/action.yml | 17 +++++++++++++++++ .github/workflows/main.yml | 10 ++++++++-- 2 files changed, 25 insertions(+), 2 deletions(-) create mode 100644 .github/actions/free-disk-space/action.yml diff --git a/.github/actions/free-disk-space/action.yml b/.github/actions/free-disk-space/action.yml new file mode 100644 index 0000000000..1eb453fa6e --- /dev/null +++ b/.github/actions/free-disk-space/action.yml @@ -0,0 +1,17 @@ +name: 'Free Space' +description: 'Free up disk space by removing files and directories that are not needed for tests.' +runs: + using: 'composite' + steps: + - name: Free space + shell: bash + run: | + echo "Disk space before cleanup:" + df -h + sudo rm -rf /usr/share/dotnet + sudo rm -rf /usr/local/lib/android + sudo rm -rf /usr/share/az_* + sudo rm -rf /opt/az + sudo rm -rf /usr/lib/google-cloud-sdk + echo "Disk space after cleanup:" + df -h diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index bd6150a0d0..260c59e71b 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -240,7 +240,8 @@ jobs: with: username: hardcoreeng password: ${{ secrets.DOCKER_ACCESS_TOKEN }} - + - name: Free space + uses: ./.github/actions/free-disk-space - name: Docker Build run: node common/scripts/install-run-rush.js docker env: @@ -371,7 +372,8 @@ jobs: with: username: hardcoreeng password: ${{ secrets.DOCKER_ACCESS_TOKEN }} - + - name: Free space + uses: ./.github/actions/free-disk-space - name: Docker Build run: node common/scripts/install-run-rush.js docker env: @@ -467,6 +469,8 @@ jobs: with: username: hardcoreeng password: ${{ secrets.DOCKER_ACCESS_TOKEN }} + - name: Free space + uses: ./.github/actions/free-disk-space - name: Docker Build run: node common/scripts/install-run-rush.js docker env: @@ -549,6 +553,8 @@ jobs: with: username: hardcoreeng password: ${{ secrets.DOCKER_ACCESS_TOKEN }} + - name: Free space + uses: ./.github/actions/free-disk-space - name: Docker Build run: node common/scripts/install-run-rush.js docker env: