github-actions: bump github/codeql-action/upload-sarif from 1f34ec16430d82636d18716acc7aaa6d843b35a9 to 3cf0a529d8434171b6af190714e8d5b7abb83927 #576
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: commit-check | |
| on: | |
| - pull_request | |
| permissions: read-all | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| env: | |
| DEBIAN_FRONTEND: "noninteractive" | |
| jobs: | |
| check-commits: | |
| name: Commit Check | |
| runs-on: ubuntu-latest | |
| container: ubuntu:20.04 | |
| steps: | |
| - name: Caching ~/.cargo | |
| uses: actions/cache@9255dc7a253b0ccc959486e2bca901246202afeb | |
| with: | |
| path: ~/.cargo | |
| key: commit-check-cargo | |
| - name: Install dependencies | |
| run: | | |
| apt update | |
| apt -y install \ | |
| libpcre2-dev \ | |
| build-essential \ | |
| autoconf \ | |
| automake \ | |
| cargo \ | |
| curl \ | |
| git \ | |
| jq \ | |
| libtool \ | |
| libpcap-dev \ | |
| libnet1-dev \ | |
| libyaml-0-2 \ | |
| libyaml-dev \ | |
| libcap-ng-dev \ | |
| libcap-ng0 \ | |
| libmagic-dev \ | |
| libnetfilter-queue-dev \ | |
| libnetfilter-queue1 \ | |
| libnfnetlink-dev \ | |
| libnfnetlink0 \ | |
| libhiredis-dev \ | |
| libjansson-dev \ | |
| libevent-dev \ | |
| libevent-pthreads-2.1-7 \ | |
| libpython2.7 \ | |
| libssl-dev \ | |
| make \ | |
| parallel \ | |
| pkg-config \ | |
| python3-yaml \ | |
| rustc \ | |
| software-properties-common \ | |
| zlib1g \ | |
| zlib1g-dev | |
| - run: echo "$HOME/.cargo/bin" >> $GITHUB_PATH | |
| - name: Installing sccache | |
| run: | | |
| (cd /tmp && curl -OL https://github.com/mozilla/sccache/releases/download/0.2.13/sccache-0.2.13-x86_64-unknown-linux-musl.tar.gz) | |
| mkdir -p "$HOME/.cargo/bin" | |
| (cd "$HOME/.cargo/bin" && tar xvf /tmp/sccache-0.2.13-x86_64-unknown-linux-musl.tar.gz --strip-components=1 --wildcards '*/sccache') | |
| echo "RUSTC_WRAPPER=sccache" >> $GITHUB_ENV | |
| - name: Install cbindgen | |
| run: | | |
| cd $HOME/.cargo/bin | |
| curl -OL https://github.com/eqrion/cbindgen/releases/download/v0.24.3/cbindgen | |
| chmod 755 cbindgen | |
| - uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 | |
| with: | |
| fetch-depth: 0 | |
| # The action above is supposed to do this for us, but it doesn't appear to stick. | |
| - run: /usr/bin/git config --global --add safe.directory /__w/suricata/suricata | |
| - run: git fetch | |
| - name: Building all commits | |
| run: | | |
| echo "Building commits from ${GITHUB_BASE_REF}." | |
| for rev in $(git rev-list --reverse origin/${GITHUB_BASE_REF}...); do | |
| git checkout $rev | |
| echo "Building rev ${rev}" | tee -a build_log.txt | |
| ./autogen.sh >> build_log.txt 2>&1 | |
| CC="sccache gcc" ./configure --enable-warnings --enable-unittests --disable-lua >> build_log.txt 2>&1 | |
| if ! make -j2 >> build_log.txt 2>&1; then | |
| echo "::error ::Failed to build rev ${rev}" | |
| tail -n 50 build_log.txt | |
| exit 1 | |
| fi | |
| make -ik distclean > /dev/null | |
| done | |
| - run: sccache -s | |
| - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a | |
| name: Uploading build log | |
| if: always() | |
| with: | |
| name: build_log | |
| path: build_log.txt |