diff --git a/vagrantfile b/vagrantfile index c09c214..3400efe 100644 --- a/vagrantfile +++ b/vagrantfile @@ -34,17 +34,17 @@ Vagrant.configure("2") do |config| SCRIPT $serve_script = <<-SCRIPT - cat <<-EOF > /usr/bin/serve - #!/usr/bin/env bash - URL="${1:-http://localhost:5000}" - /usr/bin/tty-server -web_address :5000 --sender_address :6543 -url "$URL" - EOF + cat << EOD > /usr/bin/serve +#!/usr/bin/env bash +URL="${1:-http://localhost:5000}" +/usr/bin/tty-server -web_address :5000 --sender_address :6543 -url "$URL" +EOD chmod a+x /usr/bin/serve SCRIPT config.vm.provision "file", source: ".", destination: "$HOME/go/src/github.com/elisescu/tty-server" - config.vm.provision "shell", inline: 'mv "/home/vagrant/go" "/go"' - config.vm.provision "shell", inline: $install_script - config.vm.provision "shell", inline: $serve_script + config.vm.provision "shell", inline: 'mv "/home/vagrant/go" "/go"', name: "move_go" + config.vm.provision "shell", inline: $install_script, name: "install" + config.vm.provision "shell", inline: $serve_script, name: "serve" end