summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordrebs <drebs@riseup.net>2011-03-25 16:46:20 -0300
committerdrebs <drebs@riseup.net>2011-03-25 16:46:20 -0300
commit5123a9507cb362c1308acb2fef939abe79c2e575 (patch)
tree380bcba7c4820b7071a052e710acca7f137266e8
parent374d403d3417b72bd54edfed73ee193d21b5d5bb (diff)
downloadpuppet-ekeyd-5123a9507cb362c1308acb2fef939abe79c2e575.tar.gz
puppet-ekeyd-5123a9507cb362c1308acb2fef939abe79c2e575.tar.bz2
squeeze does not have /proc/bus/usb/devices
-rw-r--r--lib/facter/ekeyd.rb3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/facter/ekeyd.rb b/lib/facter/ekeyd.rb
index a201e7f..7521948 100644
--- a/lib/facter/ekeyd.rb
+++ b/lib/facter/ekeyd.rb
@@ -1,7 +1,6 @@
Facter.add('ekeyd_key_present') do
confine :kernel => %w{Linux}
setcode do
- FileTest.exists?('/proc/bus/usb/devices') && \
- !(File.read('/proc/bus/usb/devices') =~ /Product=Entropy Key/).nil?
+ !Kernel.exec('lsusb | grep "Entropy Key"').empty?
end
end