From c91230579f1e65aae1d5f4eb9e314710f7889ac9 Mon Sep 17 00:00:00 2001 From: Tarik Moussa Date: Sun, 17 May 2026 22:12:30 +0200 Subject: [PATCH] ci: limit CGAL build to -j2 and nice -n 19 to protect Pi web server MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit -j$(nproc) during CGAL+Eigen template compilation consumed ~1.5-2 GB peak RAM on the Raspberry Pi CI runner, starving the Gitea web server. Changes: - CGAL build: -j$(nproc) → -j2 (halves peak memory, ~700 MB per process) - Both builds: nice -n 19 (lowest CPU priority, web server keeps preemption) - test-cgal container: hard memory cap --memory=1400m --memory-swap=1400m so the container is OOM-killed rather than taking down the whole system Co-Authored-By: Claude Sonnet 4.6 --- .gitea/workflows/cpp-tests.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/cpp-tests.yml b/.gitea/workflows/cpp-tests.yml index 6f3f86a..3ec4b73 100644 --- a/.gitea/workflows/cpp-tests.yml +++ b/.gitea/workflows/cpp-tests.yml @@ -27,7 +27,7 @@ jobs: run: cmake -S code -B build -DCMAKE_BUILD_TYPE=Release - name: Build - run: cmake --build build --target conformallab_tests -j$(nproc) + run: nice -n 19 cmake --build build --target conformallab_tests -j$(nproc) - name: Run tests run: > @@ -66,6 +66,7 @@ jobs: runs-on: eulernest container: image: git.eulernest.eu/conformallab/ci-cpp:latest + options: "--memory=1400m --memory-swap=1400m" steps: - uses: actions/checkout@v4 @@ -74,7 +75,7 @@ jobs: run: cmake -S code -B build -DWITH_CGAL_TESTS=ON -DCMAKE_BUILD_TYPE=Release - name: Build CGAL-Tests - run: cmake --build build --target conformallab_cgal_tests -j$(nproc) + run: nice -n 19 cmake --build build --target conformallab_cgal_tests -j2 - name: Run CGAL-Tests run: >