Merge pull request #5315 from vadorovsky/vagrant-ipv6

vagrant: Enable IPv6 and IP forwarding, set NFS options
pull/5343/head
Michal Rostecki 3 years ago committed by GitHub
commit dd541e8557
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

6
Vagrantfile vendored

@ -40,7 +40,11 @@ Vagrant.configure("2") do |config|
if Vagrant.has_plugin?("vagrant-timezone") if Vagrant.has_plugin?("vagrant-timezone")
config.timezone.value = :host config.timezone.value = :host
end end
config.vm.synced_folder HOME, HOME, type: MOUNT_TYPE if "#{MOUNT_TYPE}" == "nfs"
config.vm.synced_folder HOME, HOME, type: "nfs", mount_options: ["vers=3,tcp"]
else
config.vm.synced_folder HOME, HOME, type: MOUNT_TYPE
end
if NUM_NODES==0 if NUM_NODES==0
provision(config.vm, 0) provision(config.vm, 0)

@ -68,6 +68,19 @@ cat <<\EOF >/etc/motd
EOF EOF
# --- Enable IPv6 and IP forwarding
sysctl -w net.ipv4.ip_forward=1
sysctl -w net.ipv6.conf.all.disable_ipv6=0
sysctl -w net.ipv6.conf.all.forwarding=1
sed -i \
-e "/^net.ipv6.conf.all.disable_ipv6 = 1/d" \
/etc/sysctl.conf
cat <<EOF >>/etc/sysctl.conf
net.ipv4.ip_forward = 1
net.ipv6.conf.all.disable_ipv6 = 0
net.ipv6.conf.all.forwarding = 1
EOF
# --- Utility function to download go # --- Utility function to download go
download_go() { download_go() {
goversion=$(grep "golang:" Dockerfile.dapper | sed -e 's/.*golang:\(.*\)-.*/\1/') goversion=$(grep "golang:" Dockerfile.dapper | sed -e 's/.*golang:\(.*\)-.*/\1/')

Loading…
Cancel
Save