The Puppet Labs Issue Tracker has Moved: https://tickets.puppetlabs.com

This issue tracker is now in read-only archive mode and automatic ticket export has been disabled. Redmine users will need to create a new JIRA account to file tickets using https://tickets.puppetlabs.com. See the following page for information on filing tickets with JIRA:

Bug #14541

Facter Util Manufacturer detect dmidecode

Added by Nan Liu over 3 years ago. Updated over 3 years ago.

Status:AcceptedStart date:05/16/2012
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:-
Target version:-
Keywords: Affected Facter version:
Branch:

We've Moved!

Ticket tracking is now hosted in JIRA: https://tickets.puppetlabs.com


Description

We should use facter.util.resolution instead of FileTest.exists? with hard coded filepath in util/manufacturer.rb:

when 'Linux', 'GNU/kFreeBSD'
  return nil unless FileTest.exists?("/usr/sbin/dmidecode")
when 'FreeBSD'
  return nil unless FileTest.exists?("/usr/local/sbin/dmidecode")
when 'NetBSD'
  return nil unless FileTest.exists?("/usr/pkg/sbin/dmidecode")

History

#1 Updated by Krzysztof Wilczynski over 3 years ago

Hi,

This might be another use-case which will justify addition of “which”-alike concept to Facter, as per what was mentioned in #13396, instead of just having File#exists? there.

KW

#2 Updated by Anonymous over 3 years ago

  • Status changed from Unreviewed to Accepted
  • Assignee set to Anonymous

Also available in: Atom PDF