Fix coverity scan (#8388)
* Fix coverity scan * Add path filter to pull_request: condition * Add missing dependency
This commit is contained in:
parent
53d0634b02
commit
a18ec2d2d8
|
@ -4,6 +4,10 @@ name: Coverity Scan
|
|||
on:
|
||||
schedule:
|
||||
- cron: '0 1 * * *'
|
||||
pull_request:
|
||||
paths:
|
||||
- .github/workflows/coverity.yml
|
||||
- coverity-scan.sh
|
||||
jobs:
|
||||
coverity:
|
||||
if: github.repository == 'netdata/netdata'
|
||||
|
@ -12,12 +16,18 @@ jobs:
|
|||
- name: Checkout
|
||||
uses: actions/checkout@v2
|
||||
- name: Prepare environment
|
||||
env:
|
||||
DEBIAN_FRONTEND: 'noninteractive'
|
||||
run: |
|
||||
./packaging/installer/install-required-packages.sh --dont-wait --non-interactive netdata
|
||||
sudo apt-get install -y libjson-c-dev libipmimonitoring-dev libcups2-dev libsnappy-dev \
|
||||
libprotobuf-dev libprotoc-dev libssl-dev protobuf-compiler
|
||||
./packaging/installer/install-required-packages.sh \
|
||||
--dont-wait --non-interactive netdata
|
||||
sudo apt-get install -y libjson-c-dev libipmimonitoring-dev \
|
||||
libcups2-dev libsnappy-dev libprotobuf-dev \
|
||||
libprotoc-dev libssl-dev protobuf-compiler \
|
||||
libnetfilter-acct-dev
|
||||
- name: Run coverity-scan
|
||||
env:
|
||||
REPOSITORY: 'netdata/netdata'
|
||||
COVERITY_SCAN_TOKEN: ${{ secrets.COVERITY_SCAN_TOKEN }}
|
||||
COVERITY_SCAN_SUBMIT_MAIL: ${{ secrets.COVERITY_SCAN_SUBMIT_MAIL }}
|
||||
run: |
|
||||
|
|
|
@ -48,8 +48,7 @@ source packaging/installer/functions.sh || echo "Failed to fully load the functi
|
|||
cpus=$(find_processors)
|
||||
[ -z "${cpus}" ] && cpus=1
|
||||
|
||||
if [ -f ".coverity-scan.conf" ]
|
||||
then
|
||||
if [ -f ".coverity-scan.conf" ]; then
|
||||
source ".coverity-scan.conf"
|
||||
fi
|
||||
|
||||
|
@ -77,8 +76,7 @@ fi
|
|||
# when debugging is enabled
|
||||
# used to hide the token when debugging is not enabled
|
||||
debugrun() {
|
||||
if [ "${COVERITY_SUBMIT_DEBUG}" = "1" ]
|
||||
then
|
||||
if [ "${COVERITY_SUBMIT_DEBUG}" = "1" ]; then
|
||||
run "${@}"
|
||||
return $?
|
||||
else
|
||||
|
|
Loading…
Reference in New Issue