summaryrefslogtreecommitdiff
path: root/tool/travis_disable_ipv6.sh
blob: 97ba179d6e94250726c98228e2b6d23fd6899064 (plain)
1
2
3
4
5
6
7
8
9
10
11
#!/bin/bash
set -ex
ip a
sudo sysctl -w net.ipv6.conf.all.disable_ipv6=1
sudo sysctl -w net.ipv6.conf.default.disable_ipv6=1
sudo sysctl -w net.ipv6.conf.lo.disable_ipv6=1
ip a

cat /etc/hosts
sudo ruby -e "hosts = File.read('/etc/hosts').sub(/^::1\s*localhost.*$/, ''); File.write('/etc/hosts', hosts)"
cat /etc/hosts