Skip to content

Commit

Permalink
github: Simplify workflow for self-hosted runner
Browse files Browse the repository at this point in the history
Signed-off-by: Stéphane Graber <[email protected]>
  • Loading branch information
stgraber committed Dec 6, 2024
1 parent ca3bcf9 commit e50d845
Showing 1 changed file with 6 additions and 39 deletions.
45 changes: 6 additions & 39 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,40 +22,13 @@ jobs:
- name: Checkout
uses: actions/checkout@v4

- name: Setup tmate session
uses: mxschmitt/action-tmate@v3
with:
detached: true

- name: Performance tuning
run: |
set -eux
# optimize ext4 FSes for performance, not reliability
for fs in $(findmnt --noheading --type ext4 --list --uniq | awk '{print $1}'); do
# nombcache and data=writeback cannot be changed on remount
sudo mount -o remount,noatime,barrier=0,commit=6000 "${fs}" || true
done
# disable dpkg from calling sync()
echo "force-unsafe-io" | sudo tee /etc/dpkg/dpkg.cfg.d/force-unsafe-io
- name: Reclaim some space
- name: Install dependencies
run: |
set -eux
sudo apt-get autopurge --yes snapd moby-containerd docker
sudo ip link delete docker0
sudo nft flush ruleset
# This was inspired from https://github.com/easimon/maximize-build-space
df -h /
# dotnet
sudo rm -rf /usr/share/dotnet
# android
sudo rm -rf /usr/local/lib/android
# haskell
sudo rm -rf /opt/ghc
df -h /
sudo apt-get install --yes \
debian-archive-keyring \
make \
pipx \
qemu-utils
- name: Setup Incus
run: |
Expand All @@ -67,12 +40,6 @@ jobs:
run: |
pipx install git+https://github.com/systemd/mkosi.git
- name: Install dependencies
run: |
sudo apt-get install --yes \
debian-archive-keyring \
qemu-utils
- name: Build initial image
run: |
make
Expand Down

0 comments on commit e50d845

Please sign in to comment.