open-nomad/scripts/travis.sh
Mahmood Ali 6fb80e5cc2 ci: ignore background ping errors
We attempt to kill background ping process twice, and sometimes the
second kill fails, e.g.
https://travis-ci.org/hashicorp/nomad/jobs/486050357, let's not fail the job.
2019-01-29 21:21:32 -05:00

23 lines
424 B
Bash
Executable file

#!/bin/bash
set -e
export PING_SLEEP=60
bash -c "while true; do echo \$(date) - building ...; sleep $PING_SLEEP; done" &
PING_LOOP_PID=$!
trap 'kill ${PING_LOOP_PID} || true' EXIT HUP INT QUIT TERM
if [ "$RUN_STATIC_CHECKS" ]; then
make check
if [ "$TRAVIS_OS_NAME" == "linux" ]; then
make checkscripts
fi
fi
NOMAD_SLOW_TEST=1 make test
TEST_OUTPUT=$?
kill $PING_LOOP_PID || true
exit $TEST_OUTPUT