From a4bdee82c3a8a340b81b31bb911c04e33e3d44f8 Mon Sep 17 00:00:00 2001 From: Michael Davidsaver Date: Fri, 19 Jun 2020 20:46:04 -0700 Subject: [PATCH] travis fixup networking --- .ci-local/travis-fixup.sh | 19 +++++++++++++++++++ .travis.yml | 1 + 2 files changed, 20 insertions(+) create mode 100755 .ci-local/travis-fixup.sh diff --git a/.ci-local/travis-fixup.sh b/.ci-local/travis-fixup.sh new file mode 100755 index 000000000..7d1ea8235 --- /dev/null +++ b/.ci-local/travis-fixup.sh @@ -0,0 +1,19 @@ +#!/bin/sh +set -e -u -x + +env|grep TRAVIS + +[ "$TRAVIS_OS_NAME" = "linux" ] || exit 0 + +# Ensure there is an interface with a (correct) broadcast address +# eg. 'trusty' VMs have interface broadcast address mis-configured +# (why oh why do people insist on setting this explicitly?) + +sudo ip tuntap add dev tap42 mode tap + +sudo ip addr add 192.168.240.1/24 broadcast + dev tap42 + +sudo ip link set dev tap42 up + +# note that this device will be UP but not RUNNING +# so java will see it as not UP since java confuses UP and RUNNING diff --git a/.travis.yml b/.travis.yml index a2f16784b..45f3a0073 100644 --- a/.travis.yml +++ b/.travis.yml @@ -35,6 +35,7 @@ addons: update: true install: + - ./.ci-local/travis-fixup.sh - ./.ci/travis/prepare.sh script: