summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBryan McLellan <btm@loftninjas.org>2014-12-22 12:14:28 -0500
committerLamont Granquist <lamont@scriptkiddie.org>2015-01-27 12:12:49 -0800
commit9bfff4c5c2e3ae38f6322e0d50d278388aadc0f2 (patch)
tree4306672656f4b7b1f1dc093b65392f379a293ee6
parentba4e1e49bc448008a6782d09f3368522f219ace4 (diff)
downloadchef-9bfff4c5c2e3ae38f6322e0d50d278388aadc0f2.tar.gz
Add comments to trusted_certs_content
It's initially confusing why #trusted_certs has commands embedded in the certificates. I've added comments to try to reduce that confusion for the next person.
-rw-r--r--lib/chef/knife/core/bootstrap_context.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/chef/knife/core/bootstrap_context.rb b/lib/chef/knife/core/bootstrap_context.rb
index f7fee023de..60db34c8d0 100644
--- a/lib/chef/knife/core/bootstrap_context.rb
+++ b/lib/chef/knife/core/bootstrap_context.rb
@@ -49,6 +49,8 @@ class Chef
@secret
end
+ # Contains commands and content, see trusted_certs_content
+ # TODO: Rename to trusted_certs_script
def trusted_certs
@trusted_certs ||= trusted_certs_content
end
@@ -159,6 +161,9 @@ CONFIG
end
private
+
+ # Returns a string for copying the trusted certificates on the workstation to the system being bootstrapped
+ # This string should contain both the commands necessary to both create the files, as well as their content
def trusted_certs_content
content = ""
if @chef_config[:trusted_certs_dir]