» Chef Apply Provisioner
The Vagrant Chef Apply provisioner allows you to provision the guest usingChef, specifically with.
Chef Apply is ideal for people who are already experienced with Chef and theChef ecosystem. Specifically, this documentation page does not cover how useChef or how to write Chef recipes.
Warning: If you are not familiar with Chef and Vagrant already,we recommend starting with the shellprovisioner.
This section lists the complete set of available options for the Chef Applyprovisioner. More detailed examples of how to use the provisioner areavailable below this section.
(string) - Advanced! The location on the guest where thegenerated recipe file should be stored. For most use cases, it is unlikely youwill need to customize this value. The default value is
/tmp/vagrant-chef-apply-#
where is a unique counter generated byVagrant to prevent collisions.
In addition to all the options listed above, the Chef Apply provisioner supportsthe common options for all Chef provisioners.
The easiest way to get started with the Chef Apply provisioner is to justspecify an inline. Forexample:
Since single-line Chef recipes are rare, you can also specify the recipe using a"heredoc":
Finally, if you would prefer to store the recipe as plain-text, you can set therecipe to the contents of a file:
The Vagrant Chef Apply provisioner does not support roles. Please use adifferent Vagrant Chef provisioner if you need support for roles.
The Vagrant Chef Apply provisioner does not support data_bags. Please use adifferent Vagrant Chef provisioner if you need support for data_bags.