summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Smith <tsmith@chef.io>2018-04-30 13:47:04 -0700
committerTim Smith <tsmith@chef.io>2018-06-11 11:22:08 -0700
commit3a7571cc84a0b88ddc8ddf01e929e11ce8b041eb (patch)
tree3fb035865ac37aa7cc1679366e61f66cc4b4ab72
parent9894e92bfe91a588a8fe6ba4c9da70fcbf1a0440 (diff)
downloadchef-3a7571cc84a0b88ddc8ddf01e929e11ce8b041eb.tar.gz
Fix erb source location
Signed-off-by: Tim Smith <tsmith@chef.io>
-rw-r--r--lib/chef/resource/ssh_known_hosts_entry.rb5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/chef/resource/ssh_known_hosts_entry.rb b/lib/chef/resource/ssh_known_hosts_entry.rb
index ded80b6a53..c3fcd15627 100644
--- a/lib/chef/resource/ssh_known_hosts_entry.rb
+++ b/lib/chef/resource/ssh_known_hosts_entry.rb
@@ -40,7 +40,7 @@ class Chef
default: "rsa"
property :port, Integer,
- description: "The server port that ssh-keyscan will use to gather the public key.",
+ description: "The server port that the ssh-keyscan command will use to gather the public key.",
default: 22
property :timeout, Integer,
@@ -88,7 +88,8 @@ class Chef
r = with_run_context :root do
find_resource(:template, "update ssh known hosts file #{new_resource.file_location}") do
- source "ssh_known_hosts.erb"
+ source ::File.expand_path("../support/ssh_known_hosts.erb", __FILE__)
+ local true
path new_resource.file_location
owner new_resource.owner
group new_resource.group