Question

I'm digging into what it will take to migrate my development environments to Vagrant and I'm having some trouble getting a handle on the VM provisioning process with chef. I've never used chef before and the Vagrant docs in this area intentionally weak (out of scope) so I could use a hand.

I'd like to make this as portable as possible, so I thought it made sense to load cookbooks from a URL so this is what I'm trying in my Vagrantfile:

config.vm.provision :chef_solo do |chef|
    chef.recipe_url = 'https://github.com/opscode/cookbooks/tarball/master'
    chef.add_recipe 'nginx'
    chef.add_recipe 'mysql'
    chef.add_role 'web'

    # You may also specify custom JSON attributes:
    # chef.json = { :mysql_password => '' }
end

I don't think that there's any question that I'm simply misunderstanding something, but I haven't found a documentation source that seems like it fits this Vagrant context.

Thanks.

No correct solution

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top