I am facing a issue here.
My vagrantfile creats two vms(vm1, vm2)
But some configurations of vm1 need to be done after vm2. Flow is like this.
1. Create Vm1 , configure : Done
2. Create Vm2, configure : Done
3. Additional Configurion of Vm1: Need help here
How can I specify step 3 in Vagrantfile.
You can take shell as example for configuaration.
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.box = "hashicorp/precise64"
#this is global, will be run on both nodes, ie normal provision
config.vm.provision "shell", inline: "hello global provision"
config.vm.define "n2" do |n2|
n2.vm.hostname = "n2"
end
config.vm.define "n1" do |n1|
n1.vm.hostname = "n1"
#this is n1 local, at this point n2 already exists.
n1.vm.provision "shell", inline: "hello n1 provision"
end
end
--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
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 vagrant-up+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/a9f5e9ec-4612-4d0e-8a45-e69ddf44bcd5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to a topic in the Google Groups "Vagrant" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/vagrant-up/28enLRixabk/unsubscribe.
To unsubscribe from this group and all its topics, send an email to vagrant-up+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CAHqq0exkJbqqRvnAmPu91fTXLRBDQ8D_ANWggBtTZur_2OMUbw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to a topic in the Google Groups "Vagrant" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/vagrant-up/28enLRixabk/unsubscribe.
To unsubscribe from this group and all its topics, send an email to vagrant-up+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CAHqq0ez%2BLjuL50TrYWpD8c44Qc0DzNG_UpUOr0UWKkRv7s3%3D1Q%40mail.gmail.com.
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 vagrant-up+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CA%2B8yFHY%2B96spxKMNKEyGXi34o7PzU7HN610uvLr9haS1pTg1fQ%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CANhAuoBakvqnFzQXgdfYHgQaw6FB5BaewUjjVP_YhJ_Wp%3DQnRQ%40mail.gmail.com.