Order of provision in multi_node setup

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

Order of provision in multi_node setup

Eswar Vandanapu

I am wondering how the provision file setup is determined in mutinode vagrant setup?   I am hoping that in the setup below, first the provisioning scripts for individual nodes are executed before running the scripts from the global.  This allows me to setup the puppet facts before running puppet on each node.  What I am noticing is that scripts from config.vm.provision are running first.  Is there any thing I can do to control this order?

Vagrant.configure("2") do |config|

  config.vm.define :server do |aserver|
    aserver.vm.hostname = "server"
    aserver.vm.network :forwarded_port, guest: 8000, host: 8000
    aserver.vm.provision :shell, :path => "vagrant/create_web_fact.sh"   

  config.vm.define :worker do |aworker|

  config.vm.define :notebook do |anotebook|
      anotebook.vm.network :forwarded_port, guest: 8888, host: 8888
  config.vm.box = "precise64"
  config.vm.provision :shell, :path => "vagrant/provision.sh"
  config.vm.synced_folder "..", "/opt/source"
  config.vm.synced_folder ".", "/etc/puppet"

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 [hidden email].
For more options, visit https://groups.google.com/groups/opt_out.