Looking for exactly the same thing. My first thought was shelling out to `vagrant ssh-config other_node`, but that get's evaluated too early...
I could imagine you could do this at the right time via the vagrant-triggers plugin, but haven't tried it yet: https://github.com/emyl/vagrant-triggers Cheers, Torben On Sat, Jan 25, 2014 at 12:55 AM, David Petzel <[email protected]>wrote: > I'm trying to figure out how I can read information about one machine and > use it to set a an attribute (chef solo provisioner) on a second instance. > For the sake of the discussion lets say I have a two machine configuration > using a cloud provider (not virtualbox). We'll say I have DB and WEB. I > want to bring up the DB box first and then once its been given an IP, I > want to grab its IP and populate a node attribute (via the chef.json hash). > I do understand that this is easy with chef-server provisioner, but trying > to accomplish it with chef-solo provisioner. > > So the pseudo code would be something like: > web.vm.provision :chef_solo do |chef| > chef.blah > chef.json = {:db_server_ip => find_db_serverip()} > end > > Can something like this be done? > > Thanks > > -- > 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/groups/opt_out. > -- 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/groups/opt_out.
