Set attribute whitelists for Knife-Zero

This prevents all attributes to be written in the node files. We don't
want that data stored in git.
See https://knife-zero.github.io/40_configuration/
This commit is contained in:
Greg 2019-10-10 12:34:55 +02:00
parent f5858a8a6e
commit 8fdafa1484
1 changed files with 21 additions and 0 deletions

View File

@ -11,3 +11,24 @@ local_mode true # Chef local mode, replacing Solo
cookbook_copyright 'Kosmos'
cookbook_license 'none'
cookbook_email 'mail@kosmos.org'
# Knife-Zero config, see https://knife-zero.github.io/40_configuration/
# Prevent attributes from being saved to the node files
knife[:automatic_attribute_whitelist] = %w[
fqdn
os
os_version
hostname
ipaddress
roles
recipes
ipaddress
platform
platform_version
cloud
cloud_v2
chef_packages
]
knife[:default_attribute_whitelist] = []
knife[:normal_attribute_whitelist] = ['knife_zero']
knife[:override_attribute_whitelist] = []