aboutsummaryrefslogtreecommitdiff
path: root/.github/workflows
diff options
context:
space:
mode:
authorIvan Nardi <12729895+IvanNardi@users.noreply.github.com>2024-02-01 20:30:27 +0100
committerGitHub <noreply@github.com>2024-02-01 20:30:27 +0100
commit8fbef7fb5ab682b7aa9c92e4fd6e106698eb4ae1 (patch)
treed1fc0a09370ec44ca227b2b2c0ffaad5a43aae3d /.github/workflows
parent4c9446379f7bc17791c3b1f36473d19064d26fb5 (diff)
GitHub Actions: update to latest macOS runners (#2293)
Add a simple job with macos-14 on M1. https://github.blog/changelog/2024-01-30-github-actions-introducing-the-new-m1-macos-runner-available-to-open-source/) There are some issues with external dependencies (they are installed but autoconf script doens;t find them) so keep it simple. On macos-13 it seems that: * there is no `realpath` program (even if coreutils has been installed...) * most of the filesystem is read only (we can't write on /usr/lib). So I change ``` make install DESTDIR=$(realpath _install) ls -alhHR _install ``` to ``` DESTDIR=/tmp/ndpi make install ls -alhHR /tmp/ndpi ``` for all the jobs Fix a warning on GitHub logs: ``` Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/. ```
Diffstat (limited to '.github/workflows')
-rw-r--r--.github/workflows/build-msbuild.yml6
-rw-r--r--.github/workflows/build.yml30
-rw-r--r--.github/workflows/build_scheduled.yml12
-rw-r--r--.github/workflows/cifuzz.yml2
-rw-r--r--.github/workflows/codeql.yml8
5 files changed, 32 insertions, 26 deletions
diff --git a/.github/workflows/build-msbuild.yml b/.github/workflows/build-msbuild.yml
index a121f1a8a..323662c53 100644
--- a/.github/workflows/build-msbuild.yml
+++ b/.github/workflows/build-msbuild.yml
@@ -15,10 +15,10 @@ jobs:
runs-on: windows-latest
steps:
- name: Checkout
- uses: actions/checkout@v3
+ uses: actions/checkout@v4
- name: Add msbuild to PATH
- uses: microsoft/setup-msbuild@v1.1
+ uses: microsoft/setup-msbuild@v2
- name: Download NuGet packages
run: msbuild windows/nDPI.sln -t:restore -p:RestorePackagesConfig=true
@@ -36,7 +36,7 @@ jobs:
run: msbuild windows/nDPI.sln -t:rebuild -property:Configuration=Debug-ndpiReader
- name: Upload artifacts
- uses: actions/upload-artifact@v3
+ uses: actions/upload-artifact@v4
with:
name: build-artifacts
path: windows/bin
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index 3a7d44aa8..eb237ea09 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -16,11 +16,11 @@ jobs:
env:
CFLAGS: -Werror
steps:
- - uses: actions/checkout@v3
+ - uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Python 3.9
- uses: actions/setup-python@v4
+ uses: actions/setup-python@v5
with:
python-version: "3.9"
- name: Install Ubuntu Prerequisites
@@ -47,7 +47,7 @@ jobs:
name: Test Utils (ubuntu-latest)
runs-on: ubuntu-latest
steps:
- - uses: actions/checkout@v3
+ - uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install Ubuntu Prerequisites
@@ -77,7 +77,7 @@ jobs:
matrix:
# ubuntu-latest == ubuntu-22.04
# macOS-latest == macos-12
- os: ["ubuntu-latest", "ubuntu-20.04", "macOS-latest", "macos-11", "windows-latest"]
+ os: ["ubuntu-latest", "ubuntu-20.04", "macOS-latest", "macos-13", "windows-latest"]
arch: ["x86_64"]
gcrypt: ["--with-local-libgcrypt", ""]
compiler: ["cc"]
@@ -168,11 +168,11 @@ jobs:
msan: "" # Disable sanitizer on macos
nBPF: ""
- compiler: "cc"
- os: macos-12
+ os: macos-14
arch: "x86_64"
gcrypt: ""
- pcre: "--with-pcre2"
- maxminddb: "--with-maxminddb"
+ pcre: ""
+ maxminddb: ""
msan: "" # Disable sanitizer on macos
nBPF: ""
- compiler: "cc"
@@ -204,7 +204,7 @@ jobs:
if: startsWith(matrix.os, 'ubuntu') && !startsWith(matrix.arch, 'x86_64')
run: |
docker run --rm --privileged multiarch/qemu-user-static:register --reset
- - uses: actions/checkout@v3
+ - uses: actions/checkout@v4
with:
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
- name: Install Ubuntu Prerequisites
@@ -315,11 +315,17 @@ jobs:
msys2 -c 'make all'
msys2 -c 'ldd ./example/ndpiReader.exe'
- name: Build nDPI
- if: startsWith(matrix.arch, 'x86_64') && !startsWith(matrix.os, 'windows')
+ if: startsWith(matrix.arch, 'x86_64') && !startsWith(matrix.os, 'windows') && !startsWith(matrix.os, 'macos-14')
run: |
make all
make -C example ndpiSimpleIntegration
make -C rrdtool
+ - name: Build nDPI (MacOS M1)
+ if: startsWith(matrix.os, 'macos-14')
+ run: |
+ make all
+ make -C example ndpiSimpleIntegration
+ #There are somes issues with librrd
- name: Print nDPI long help
if: startsWith(matrix.arch, 'x86_64') && !startsWith(matrix.os, 'windows')
run: |
@@ -327,8 +333,8 @@ jobs:
- name: Install nDPI
if: startsWith(matrix.arch, 'x86_64') && !startsWith(matrix.os, 'windows')
run: |
- make install DESTDIR=$(realpath _install)
- ls -alhHR _install
+ DESTDIR=/tmp/ndpi make install
+ ls -alhHR /tmp/ndpi
- name: Test nDPI [SYMBOLS]
if: (startsWith(matrix.os, 'ubuntu') || startsWith(matrix.os, 'mac')) && startsWith(matrix.arch, 'x86_64')
run: |
@@ -341,7 +347,7 @@ jobs:
./tests/do.sh
- name: Test nDPI [UNIT]
#Some issues with masan + json-c. Disable the test as workaround
- if: startsWith(matrix.arch, 'x86_64') && !startsWith(matrix.os, 'windows') && !startsWith(matrix.msan, '--with-memory-sanitizer')
+ if: startsWith(matrix.arch, 'x86_64') && !startsWith(matrix.os, 'windows') && !startsWith(matrix.msan, '--with-memory-sanitizer') && !startsWith(matrix.os, 'macos-14')
run: |
./tests/do-unit.sh
- name: Test nDPI [DGA]
diff --git a/.github/workflows/build_scheduled.yml b/.github/workflows/build_scheduled.yml
index 55376608c..b1ca40d9c 100644
--- a/.github/workflows/build_scheduled.yml
+++ b/.github/workflows/build_scheduled.yml
@@ -12,7 +12,7 @@ jobs:
env:
CFLAGS: -Werror
steps:
- - uses: actions/checkout@v3
+ - uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install Ubuntu Prerequisites
@@ -32,7 +32,7 @@ jobs:
- name: Generate Coverage Report
run: |
make coverage
- - uses: actions/upload-artifact@v3
+ - uses: actions/upload-artifact@v4
with:
name: ndpi-coverage-report
path: coverage_report
@@ -42,7 +42,7 @@ jobs:
name: Documentation (ubuntu-latest)
runs-on: ubuntu-latest
steps:
- - uses: actions/checkout@v3
+ - uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Python 3.9
@@ -63,7 +63,7 @@ jobs:
make doc
mkdir -vp doc/_build/ndpi-documentation-upload/ndpi-documentation
mv -v doc/_build/html doc/_build/ndpi-documentation-upload/ndpi-documentation/html
- - uses: actions/upload-artifact@v3
+ - uses: actions/upload-artifact@v4
with:
name: ndpi-documentation
path: doc/_build/ndpi-documentation-upload
@@ -76,7 +76,7 @@ jobs:
GO111MODULE: on
CFLAGS: -Werror
steps:
- - uses: actions/checkout@v3
+ - uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install Ubuntu Prerequisites
@@ -104,7 +104,7 @@ jobs:
mv -v tests/cfgs/${PROFILE}/result/cpu_profile.png ndpi-performance-upload/${PROFILE}_cpu_profile.png
mv -v tests/cfgs/${PROFILE}/result/heap_profile.png ndpi-performance-upload/${PROFILE}_heap_profile.png
done
- - uses: actions/upload-artifact@v3
+ - uses: actions/upload-artifact@v4
with:
name: ndpi-performance
path: ndpi-performance-upload
diff --git a/.github/workflows/cifuzz.yml b/.github/workflows/cifuzz.yml
index d519d7302..9f4ac23a9 100644
--- a/.github/workflows/cifuzz.yml
+++ b/.github/workflows/cifuzz.yml
@@ -27,7 +27,7 @@ jobs:
run: |
exit $(ls out/artifacts |wc -l)
- name: Upload Crash (upload detected crash as artifacts)
- uses: actions/upload-artifact@v1
+ uses: actions/upload-artifact@v4
if: failure()
with:
name: ${{ matrix.sanitizer }}-artifacts
diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml
index e29fe2b4b..d62d471b5 100644
--- a/.github/workflows/codeql.yml
+++ b/.github/workflows/codeql.yml
@@ -24,10 +24,10 @@ jobs:
strategy:
fail-fast: false
matrix:
- language: [ 'cpp', 'python', 'ruby' ]
+ language: [ 'cpp', 'python' ]
steps:
- - uses: actions/checkout@v3
+ - uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install Ubuntu Prerequisites
@@ -45,7 +45,7 @@ jobs:
./autogen.sh --enable-gprof --enable-option-checking=fatal --with-pcre2 --with-maxminddb --enable-tls-sigs --enable-debug-messages
- name: Initialize CodeQL
- uses: github/codeql-action/init@v2
+ uses: github/codeql-action/init@v3
with:
languages: ${{ matrix.language }}
@@ -54,6 +54,6 @@ jobs:
make
- name: Perform CodeQL Analysis
- uses: github/codeql-action/analyze@v2
+ uses: github/codeql-action/analyze@v3
with:
category: "/language:${{matrix.language}}"