aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMicah Anderson <micah@riseup.net>2009-07-02 12:59:16 -0400
committerMicah Anderson <micah@riseup.net>2009-07-02 13:00:42 -0400
commit60eb9319d3d1c4697de349485326a9ab019f5856 (patch)
tree6f6affdaaf576507667aa005ab7799ef3c66d472
parent5161c4332a7f5b79c25c922a4450cec97b2ad276 (diff)
downloadpuppet-sshd-60eb9319d3d1c4697de349485326a9ab019f5856.tar.gz
puppet-sshd-60eb9319d3d1c4697de349485326a9ab019f5856.tar.bz2
removed the facter/sshkeys.rb, this is handled by facter now days, so it is no longer necessary to provide it
-rw-r--r--plugins/facter/sshkeys.rb45
1 files changed, 0 insertions, 45 deletions
diff --git a/plugins/facter/sshkeys.rb b/plugins/facter/sshkeys.rb
deleted file mode 100644
index 0e94a03..0000000
--- a/plugins/facter/sshkeys.rb
+++ /dev/null
@@ -1,45 +0,0 @@
-["/etc/ssh","/usr/local/etc/ssh","/etc","/usr/local/etc"].each { |dir|
- {"SSHDSAKey_key" => "ssh_host_dsa_key.pub",
- "SSHRSAKey_key" => "ssh_host_rsa_key.pub"}.each { |name,file|
- Facter.add(name ) do
- setcode do
- value = nil
- filepath = File.join(dir,file)
- if FileTest.file?(filepath)
- regex1 = %r{^(\S+) (\S+) (\S+)$}
- regex2 = %r{^(\S+) (\S+)(\s+)$}
- begin
- line = File.open(filepath).read.chomp
- if (match = regex1.match(line)) or (match = regex2.match(line))
- value = match[2]
- end
- rescue
- value = nil
- end
- end
- value
- end # end of proc
- end # end of add
- } # end of hash each
- {"SSHDSAKey_comment" => "ssh_host_dsa_key.pub",
- "SSHRSAKey_comment" => "ssh_host_rsa_key.pub"}.each { |name,file|
- Facter.add(name ) do
- setcode do
- value = nil
- filepath = File.join(dir,file)
- if FileTest.file?(filepath)
- regex = %r{^(\S+) (\S+) (\S+)$}
- begin
- line = File.open(filepath).read.chomp
- if match = regex.match(line)
- value = match[3]
- end
- rescue
- value = nil
- end
- end
- value
- end # end of proc
- end # end of add
- } # end of hash each
-} # end of dir each