Signed-off-by: Stephen Gran <steve@lobefin.net>
is3w = false
if FileTest.exist?("/proc/scsi/scsi")
IO.foreach("/proc/scsi/scsi") { |x|
- is3w = "true" if x =~ /Vendor: 3ware/
+ is3w = true if x =~ /Vendor: 3ware/
}
end
is3w
swraid = false
if FileTest.exist?("/proc/mdstat") && FileTest.exist?("/sbin/mdadm")
IO.foreach("/proc/mdstat") { |x|
- swraid = "true" if x =~ /md[0-9]+ : active/
+ swraid = true if x =~ /md[0-9]+ : active/
}
end
swraid
Facter.interfaces.split(',').each do |my_interface|
my_ip = Facter.value("ipaddress_" + my_interface)
if my_ip == service_ip
- active = "true"
+ active = true
end
end
end