Clean up white list attributes in client.rb
Both old and new styles. We define our allow list in the client.d file
This commit is contained in:
@@ -6,8 +6,9 @@
|
|||||||
ruby_block "cleanup client.rb" do
|
ruby_block "cleanup client.rb" do
|
||||||
block do
|
block do
|
||||||
fe = Chef::Util::FileEdit.new("/etc/chef/client.rb")
|
fe = Chef::Util::FileEdit.new("/etc/chef/client.rb")
|
||||||
# Delete old attributes, replaced by allow_*_attributes
|
# Delete whitelist attribute definitions, everything is defined in attributes.rb
|
||||||
fe.search_file_delete_line(/^.*_attribute_whitelist.*/)
|
fe.search_file_delete_line(/^.*_attribute_whitelist.*/)
|
||||||
|
fe.search_file_delete_line(/^allowed_.*_attributes.*/)
|
||||||
fe.write_file
|
fe.write_file
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user