The chef-client includes an option called local mode (
-z), which runs the chef-client against the chef-repo on the local machine as if it were running against a Chef server. Local mode was added to the chef-client in the 11.8 release. If you are running that version of the chef-client (or later), you should consider using local mode instead of using chef-solo.
A solo.rb file is used to specify the configuration details for chef-solo.
/etc/chef/solo.rb; use the
--configoption from the command line to change this location
solo.rbfile is present in this directory, the settings contained within that file will override the default configuration settings
This configuration file has the following settings:
file_cache_path. The default location of a lock file should not on an NF mount. Default value: a location defined by
trueduring integration testing to speed up test cycles.
0to cause a second chef-client to exit immediately.
false. When this is set to
false, notifications about individual resources being processed are suppressed (and are output at the
:infologging level). Setting this to
falsecan be useful when a chef-client is run as a daemon. Default value:
A sample solo.rb file that contains all possible settings (listed alphabetically):
add_formatter :nyan add_formatter :foo add_formatter :bar checksum_path '/var/chef/checksums' cookbook_path [ '/var/chef/cookbooks', '/var/chef/site-cookbooks' ] data_bag_path '/var/chef/data_bags' environment 'production' environment_path '/var/chef/environments' file_backup_path '/var/chef/backup' file_cache_path '/var/chef/cache' json_attribs nil lockfile nil log_level :info log_location STDOUT node_name 'mynode.example.com' recipe_url 'http://path/to/remote/cookbook' rest_timeout 300 role_path '/var/chef/roles' sandbox_path 'path_to_folder' solo false syntax_check_cache_path umask 0022 verbose_logging nil
© Chef Software, Inc.
Licensed under the Creative Commons Attribution 3.0 Unported License.
The Chef™ Mark and Chef Logo are either registered trademarks/service marks or trademarks/servicemarks of Chef, in the United States and other countries and are used with Chef Inc's permission.
We are not affiliated with, endorsed or sponsored by Chef Inc.