May 2015
Intermediate to advanced
278 pages
5h 34m
English
If running your own Chef server seems like an overkill and you're not comfortable with using the hosted Chef, you can use local mode to execute cookbooks.
my_cookbook by running the following command:
mma@laptop:~/chef-repo $ chef generate cookbook cookbooks/my_cookbook
Compiling Cookbooks... Recipe: code_generator::cookbook ...TRUNCATED OUTPUT...
my_cookbook so that it creates a temporary file:
mma@laptop:~/chef-repo $ subl cookbooks/my_cookbook/recipes/default.rb
file "/tmp/local_mode.txt" do
content "created by chef client local mode"
endLet's run my_cookbook on your local workstation using Chef client's local mode:
Read now
Unlock full access