Make CI faster (#2662)

Right now the CI takes ~30 minutes; the goal is to have it ending in
< 15 min.
The basic trick is to run the longer jobs (no_x86_64 and masan) only
with the recently updated pcaps. The same jobs will run again on schedule
(every night) testing all the traces.

This way the CI will be "green" (hopefully!) earlier while pushing new
commit/PR; full tests are simply delayed.

Details: when `NDPI_TEST_ONLY_RECENTLY_UPDATED_PCAPS` is set,
`tests/do.sh` checks only the latest 10 pcaps (i.e. the more recent pcap
added/updated) for *every* configuration.

Notes that no_x86_64 and masan jobs run twice: when pushing/merging and
on schedule (every night)
This commit is contained in:
Ivan Nardi 2025-01-11 19:09:48 +01:00 committed by GitHub
parent 957a050500
commit 655360728b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 71 additions and 16 deletions

View file

@ -130,13 +130,6 @@ jobs:
msan: ""
nBPF: ""
global_context: "--disable-global-context-support"
- compiler: "clang" # TODO: some issues with masan/clang/ubuntu-24.04
os: ubuntu-22.04
gcrypt: ""
pcre: "--with-pcre2"
maxminddb: "--with-maxminddb"
msan: "--with-memory-sanitizer --disable-memory-track-origins"
nBPF: ""
- compiler: "cc"
os: macOS-13
gcrypt: ""
@ -251,8 +244,7 @@ jobs:
run: |
NDPI_FORCE_PARALLEL_UTESTS=1 NDPI_SKIP_PARALLEL_BAR=1 ./tests/do.sh
- name: Test nDPI [UNIT]
# Some issues with masan + json-c. Disable the test as workaround
if: ${{ !startsWith(matrix.msan, '--with-memory-sanitizer') && !startsWith(matrix.os, 'macos-14') && !startsWith(matrix.os, 'macos-15') }}
if: ${{ !startsWith(matrix.os, 'macos-14') && !startsWith(matrix.os, 'macos-15') }}
run: |
./tests/do-unit.sh
- name: Test nDPI [DGA]