Hi
I am a newbie to vagrant and would like to know if something that I am
thinking of is possible. I am trying to build a devstack cluster using
vagrant. I have a set of nodes who name and ip details needs to go into
into /etc/hosts file in each of the nodes within the cluster.
I have the following at the beginning of the vagrant file:
workers = [{name: 'node1', ip: '192.168.205.11', memory: '1024', cpu: '1'},
{name: 'node2', ip: '192.168.205.12', memory: '1024', cpu: '1'}]
In the past I used to hardcode the values in the inline script as shown
below:
$script = <<SCRIPT
cat << EOF >> /etc/hosts
192.168.205.11 node1
192.168.205.12 node2
EOF
SCRIPT
But I would like to use the details in workers from within the inline
script. Is this feasible?
--
You received this message because you are subscribed to the Google Groups
"Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.