From 566f2ee0619aece95d1e2d2039f1955317809041 Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Mon, 11 Sep 2017 22:38:10 -0700 Subject: [PATCH] Fix permissions of $GOPATH in Vagrantfile Technically just the true->false is needed. The `chown -R` was a first attempt that didn't fix the bug, but it's a nice simplification. --- Vagrantfile | 2 +- scripts/vagrant-linux-priv-go.sh | 6 +----- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/Vagrantfile b/Vagrantfile index d402443a6..c31d94d59 100644 --- a/Vagrantfile +++ b/Vagrantfile @@ -19,7 +19,7 @@ Vagrant.configure(2) do |config| '/opt/gopath/src/github.com/hashicorp/nomad' vmCfg.vm.provision "shell", - privileged: true, + privileged: false, path: './scripts/vagrant-linux-unpriv-bootstrap.sh' end diff --git a/scripts/vagrant-linux-priv-go.sh b/scripts/vagrant-linux-priv-go.sh index e5cb90989..db146685f 100755 --- a/scripts/vagrant-linux-priv-go.sh +++ b/scripts/vagrant-linux-priv-go.sh @@ -21,11 +21,7 @@ install_go # Ensure that the GOPATH tree is owned by vagrant:vagrant mkdir -p /opt/gopath -chown vagrant:vagrant \ - /opt/gopath \ - /opt/gopath/src \ - /opt/gopath/src/github.com \ - /opt/gopath/src/github.com/hashicorp +chown -R vagrant:vagrant /opt/gopath # Ensure Go is on PATH if [ ! -e /usr/bin/go ] ; then