Changed 'plugins' directory name to 'lib' to reflect changes in 0.25+ puppet server.
This commit is contained in:
parent
05b0b8ab70
commit
24000d595c
6 changed files with 0 additions and 0 deletions
13
backuppc/lib/facter/backuppc_sshkey.rb
Normal file
13
backuppc/lib/facter/backuppc_sshkey.rb
Normal file
|
@ -0,0 +1,13 @@
|
|||
Facter.add('backuppc_sshkey') do
|
||||
setcode do
|
||||
begin
|
||||
match = File.read('/var/lib/BackupPC/.ssh/id_rsa.pub')[/^ssh-rsa ([^ ]+)/, 1]
|
||||
if match
|
||||
data = match
|
||||
end
|
||||
rescue
|
||||
data = ''
|
||||
end
|
||||
data
|
||||
end
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue