Information Technology Reference
In-Depth Information
chef_client:
init_style: runit
description: Common recipes for all nodes
env_run_lists:
json_class: Chef::Role
name: base
override_attributes:
run_list:
recipe[chef-client::delete_validation]
recipe[chef-client]
As we discussed in Chapter 8 , it is recommended that you restrict your use of attributes in
roles to those of default priority, to make it easier to follow the composition of attributes
when they come from multiple sources.
Because roles can have attributes, they have a place in the attribute hierarchy of precedence.
Figure 14-2 is a modified version of the attribute precedence diagram we showed you in Fig-
ure 8-3 that includes roles. Roles can override attributes defined in recipes or attribute files,
but they have a lower priority than the automatic attributes defined by ohai . Attribute set-
tings in roles are intended to be global settings that override attributes set within cookbooks.
Figure 14-2. Roles overview
Search WWH ::




Custom Search