Skip to content

Commit

Permalink
travis: cleanup coverity scan trigger
Browse files Browse the repository at this point in the history
  • Loading branch information
joergsteffens committed Nov 28, 2018
1 parent e1ec995 commit abf6665
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 22 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
Expand Up @@ -26,7 +26,7 @@ env:
# Be aware of quotas. Do not run on every branch/commit
- COVERITY_SCAN_BRANCH_PATTERN="master"
# COVERITY_SCAN_TOKEN via "travis encrypt" using the repo's public key
- secure: "J1iNtC34kDcFeeOJ6WcfFyfmRXI0dDgyh+AJvn5d4pBSAVAmkeT74i08ZMEck4Ye97LQB38M5+KSzMXyRP7cv4sB7BjAWLvKbXo90od506/6qmhqfahXa1C/lS4VrQRh48QjvnOP0eYYRP/T90sKSpyINlg48H/l2h7zL6sy5/Q="
#- secure: "J1iNtC34kDcFeeOJ6WcfFyfmRXI0dDgyh+AJvn5d4pBSAVAmkeT74i08ZMEck4Ye97LQB38M5+KSzMXyRP7cv4sB7BjAWLvKbXo90od506/6qmhqfahXa1C/lS4VrQRh48QjvnOP0eYYRP/T90sKSpyINlg48H/l2h7zL6sy5/Q="
- COVERITY_SCAN_BUILD_URL="https://scan.coverity.com/scripts/travisci_build_coverity_scan.sh"
- COVERITY_SCAN_BUILD="curl -s $COVERITY_SCAN_BUILD_URL | bash"
# -- END Coverity Scan ENV
Expand Down
11 changes: 5 additions & 6 deletions .travis/travis_before_install.sh
Expand Up @@ -5,12 +5,11 @@ sudo apt-get -qq update
sudo apt-get remove libqt4-dev
cd core
dpkg-checkbuilddeps 2> /tmp/dpkg-builddeps || true
if [ $BUILD_WEBUI ]
then
sudo -H pip install --upgrade pip urllib3==1.22
sudo -H pip install sauceclient selenium
cd ../webui
dpkg-checkbuilddeps 2>> /tmp/dpkg-builddeps || true
if [ $BUILD_WEBUI ]; then
sudo -H pip install --upgrade pip 'urllib3>=1.22'
sudo -H pip install sauceclient selenium
cd ../webui
dpkg-checkbuilddeps 2>> /tmp/dpkg-builddeps || true
fi
cat /tmp/dpkg-builddeps
sed -e "s/^.*:.*:\s//" -e "s/\s([^)]*)//g" -e "s/|/ /g" -e "s/ /\n/g" /tmp/dpkg-builddeps > /tmp/build_depends
Expand Down
35 changes: 20 additions & 15 deletions .travis/travis_before_script.sh
Expand Up @@ -9,27 +9,28 @@ print_header()
}

cd core

if [ "${COVERITY_SCAN}" ]; then
# run configure with default options
debian/rules override_dh_auto_configure
eval "$COVERITY_SCAN_BUILD"
else
print_header "build Bareos core packages"
fakeroot debian/rules binary
exit $?
fi


print_header "build Bareos core packages"
fakeroot debian/rules binary


if [ "${BUILD_WEBUI}" ]; then
cd ../webui
# to avoid timestamp conflicts while autoconfiguring we refresh every file
touch *
if [ "${COVERITY_SCAN}" ]; then
# run configure with default options
debian/rules override_dh_auto_configure
eval "$COVERITY_SCAN_BUILD"
else
print_header "build Bareos webui packages"
fakeroot debian/rules binary
fi
cd ../webui
# to avoid timestamp conflicts while autoconfiguring we refresh every file
touch *
print_header "build Bareos webui packages"
fakeroot debian/rules binary
fi


print_header "create Debian package repository"
cd ..
dpkg-scanpackages . > Packages
Expand All @@ -39,7 +40,11 @@ printf 'deb file:%s /\n' $PWD > /tmp/bareos.list
sudo cp /tmp/bareos.list /etc/apt/sources.list.d/bareos.list
cd -


print_header "install Bareos core package"
sudo apt-get -qq update
sudo apt-get install -y --force-yes bareos bareos-database-$DB
if [ "${BUILD_WEBUI}" ]; then sudo apt-get install -y --force-yes bareos-webui; fi

if [ "${BUILD_WEBUI}" ]; then
sudo apt-get install -y --force-yes bareos-webui
fi

0 comments on commit abf6665

Please sign in to comment.