summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Smith <tsmith@chef.io>2018-04-30 13:47:04 -0700
committerTim Smith <tsmith@chef.io>2018-05-30 15:18:24 -0700
commit14323e91d15b7b9314c5e0ef0d51f4e06755fd42 (patch)
tree4330a945d64e54ec5fa5f57dc916b941634bf8e2
parentc0733a2fec085559b4c3d848e9a6ed03e21b5078 (diff)
downloadchef-ssh_known_hosts.tar.gz
Fix erb source locationssh_known_hosts
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