Skip to content

Commit

Permalink
Merge pull request apache#129 from dims/e2e-tests-fix-dns-resolution-…
Browse files Browse the repository at this point in the history
…for-host-name

e2e tests - fix DNS resolution for host name
  • Loading branch information
dims authored Apr 7, 2018
2 parents 3720179 + 3479f5c commit 8ad4207
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,15 @@
export EXTERNAL_HOSTNAME=$HOSTNAME_OVERRIDE
export API_HOST_IP=$(ip route get 1.1.1.1 | awk '{print $7}')
# diagnostics - print /etc/hosts and resolv.conf
sudo cat /etc/hosts
sudo cat /etc/resolv.conf
# fixup /etc/hosts
sudo sed -i -e 's|$HOSTNAME_OVERRIDE||g' /etc/hosts
sudo echo "$API_HOST_IP $HOSTNAME_OVERRIDE" | sudo tee -a /etc/hosts
sudo cat /etc/hosts
# -E preserves the current env vars, but we need to special case PATH
sudo -E PATH=$PATH SHELLOPTS=$SHELLOPTS ./hack/local-up-cluster.sh -O
Expand Down

0 comments on commit 8ad4207

Please sign in to comment.