Put the right hostname in /etc/hosts
This commit is contained in:
parent
abfc502e49
commit
a27306ed39
|
@ -65,7 +65,7 @@ bash scripts/install_consul.sh
|
|||
bash scripts/install_vault.sh
|
||||
|
||||
# Set hostname's IP to made advertisement Just Work
|
||||
sudo sed -i -e "s/.*nomad.*/$(ip route get 1 | awk '{print $NF;exit}') nomad/" /etc/hosts
|
||||
sudo sed -i -e "s/.*nomad.*/$(ip route get 1 | awk '{print $NF;exit}') $(hostname)/" /etc/hosts
|
||||
|
||||
# CD into the nomad working directory when we login to the VM
|
||||
grep "cd /opt/gopath/src/github.com/hashicorp/nomad" ~/.profile || echo "cd /opt/gopath/src/github.com/hashicorp/nomad" >> ~/.profile
|
||||
|
|
Loading…
Reference in New Issue