Vagrant Chef Question

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Vagrant Chef Question

David Rodriguez
Currently I have my vagrant VM using vagrant-omnibus to install the chef-client.  Now I do see the first initial chef run and things are working.  Now I would think if I made a change to my cookbook and than updated it.  I should just be able to ssh to the vagrant vm and do a chef-client and the cookbook would be updated.  Well this isn't the case.  It appears that the only way to do this is to do a vagrant reload.  A reload wouldn't be so bad but it does take a few minutes for a reload.  Am I missing something?  Here is the chef portion of my vagrant file.  

NODE_NAME = Socket.gethostname.to_s + "-DEVVM"
config.omnibus.chef_version = :latest
  config.vm.provision :chef_client do |chef|
    chef.chef_server_url = "http://mychefserverurl"
    chef.validation_key_path = "validator.pem"
    chef.node_name = NODE_NAME
    chef.add_role "somerole"
  end

Any help would be greatly appreciated.  

David

--
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.
 
 
Reply | Threaded
Open this post in threaded view
|

Re: Vagrant Chef Question

Cassiano Leal
On August 7, 2013 at 12:49:48, David Rodriguez ([hidden email]) wrote:
Currently I have my vagrant VM using vagrant-omnibus to install the chef-client.  Now I do see the first initial chef run and things are working.  Now I would think if I made a change to my cookbook and than updated it.  I should just be able to ssh to the vagrant vm and do a chef-client and the cookbook would be updated.  Well this isn't the case.  It appears that the only way to do this is to do a vagrant reload.  A reload wouldn't be so bad but it does take a few minutes for a reload.  Am I missing something?  Here is the chef portion of my vagrant file.  
The command you want is “vagrant provision”.

That’ll only run the provisioners you have set up in the Vagrantfile.

NODE_NAME = Socket.gethostname.to_s + "-DEVVM"
config.omnibus.chef_version = :latest
  config.vm.provision :chef_client do |chef|
    chef.chef_server_url = "http://mychefserverurl"
    chef.validation_key_path = "validator.pem"
    chef.node_name = NODE_NAME
    chef.add_role "somerole"
  end

Any help would be greatly appreciated.  

David

-- 
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.
 
 

Cheers,
--
Cassiano Leal
http://cassianoleal.com
http://twitter.com/cassianoleal

--
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.
 
 
Reply | Threaded
Open this post in threaded view
|

Re: Vagrant Chef Question

David Rodriguez
Oh ok.  So that is the way you would run the chef-client command.  Instead of running chef-client you run vagrant provision.  Why is that?  Why not use chef-client?  Just curious. 


On Wed, Aug 7, 2013 at 1:13 PM, Cassiano Leal <[hidden email]> wrote:
On August 7, 2013 at 12:49:48, David Rodriguez ([hidden email]) wrote:
Currently I have my vagrant VM using vagrant-omnibus to install the chef-client.  Now I do see the first initial chef run and things are working.  Now I would think if I made a change to my cookbook and than updated it.  I should just be able to ssh to the vagrant vm and do a chef-client and the cookbook would be updated.  Well this isn't the case.  It appears that the only way to do this is to do a vagrant reload.  A reload wouldn't be so bad but it does take a few minutes for a reload.  Am I missing something?  Here is the chef portion of my vagrant file.  
The command you want is “vagrant provision”.

That’ll only run the provisioners you have set up in the Vagrantfile.

NODE_NAME = Socket.gethostname.to_s + "-DEVVM"
config.omnibus.chef_version = :latest
  config.vm.provision :chef_client do |chef|
    chef.chef_server_url = "http://mychefserverurl"
    chef.validation_key_path = "validator.pem"
    chef.node_name = NODE_NAME
    chef.add_role "somerole"
  end

Any help would be greatly appreciated.  

David

-- 
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.
 
 

Cheers,
--



--
David Rodriguez
SpinDance, Inc.
(616) 355-7000 x.117

--
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.