4 Facter.add("staticsync_key") do
7 keyfile = '/home/staticsync/.ssh/id_rsa.pub'
8 if FileTest.exist?(keyfile)
9 key = File.open(keyfile).read.chomp
15 Facter.add("staticsync_user_exists") do
19 if Etc.getpwnam('staticsync')
29 Facter.add("weblogsync_key") do
32 keyfile = '/home/weblogsync/.ssh/id_rsa.pub'
33 if FileTest.exist?(keyfile)
34 key = File.open(keyfile).read.chomp
40 Facter.add("weblogsync_user_exists") do
44 if Etc.getpwnam('weblogsync')
54 Facter.add("buildd_key") do
57 keyfile = '/home/buildd/.ssh/id_rsa.pub'
58 if FileTest.exist?(keyfile)
59 key = File.open(keyfile).read.chomp
65 Facter.add("buildd_user_exists") do
69 if Etc.getpwnam('buildd')
78 Facter.add("portforwarder_key") do
81 keyfile = '/home/portforwarder/.ssh/id_rsa.pub'
82 if FileTest.exist?(keyfile)
83 key = File.open(keyfile).read.chomp
89 Facter.add("portforwarder_user_exists") do
93 if Etc.getpwnam('portforwarder')
104 rescue Exception => e
108 # vim:set shiftwidth=4: