Skip to content

Commit

Permalink
Free disk space
Browse files Browse the repository at this point in the history
  • Loading branch information
rumpelsepp committed Nov 2, 2024
1 parent 0ef64a5 commit 17555b4
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 0 deletions.
28 changes: 28 additions & 0 deletions .github/actions/disk-cleanup/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Disk cleanup
description: "Cleanup disk space"
runs:
using: composite
steps:
- name: Free up disk space
shell: bash
run: |
echo "Disk space before cleanup..."
df -h /
echo "Removing unnecessary files to free up disk space..."
# https://github.com/actions/runner-images/issues/2840#issuecomment-2272410832
sudo rm -rf \
/opt/hostedtoolcache \
/opt/google/chrome \
/opt/microsoft/msedge \
/opt/microsoft/powershell \
/opt/pipx \
/usr/lib/mono \
/usr/local/julia* \
/usr/local/lib/android \
/usr/local/lib/node_modules \
/usr/local/share/chromium \
/usr/local/share/powershell \
/usr/share/dotnet \
/usr/share/swift
echo "Disk space after cleanup..."
df -h /
4 changes: 4 additions & 0 deletions .github/workflows/publish-arch-container.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,10 @@ jobs:
id-token: write

steps:
# https://github.com/actions/runner-images/issues/2840#issuecomment-1284059930
- name: Free disk space
uses: ./.github/actions/disk-cleanup

- name: Checkout repository
uses: actions/checkout@v4

Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/publish-debian-container.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,10 @@ jobs:
id-token: write

steps:
# https://github.com/actions/runner-images/issues/2840#issuecomment-1284059930
- name: Free disk space
uses: ./.github/actions/disk-cleanup

- name: Checkout repository
uses: actions/checkout@v4

Expand Down

0 comments on commit 17555b4

Please sign in to comment.