diff options
author | Matt Robinson <matt@puppetlabs.com> | 2011-05-20 16:17:37 -0700 |
---|---|---|
committer | Matt Robinson <matt@puppetlabs.com> | 2011-05-20 16:17:37 -0700 |
commit | 59173268a5c6525a4a5df55b362775d07bc6b52d (patch) | |
tree | fbba104c5d714156b3dc872b9e006107ee2a4618 /lib/facter/hardwaremodel.rb | |
parent | 024f7c99543e58ec00bb8f755a1d89d01fd5174c (diff) | |
parent | 2c5effffa0558f0cec4e84d07ee80ffa27db9a2f (diff) | |
download | facter-59173268a5c6525a4a5df55b362775d07bc6b52d.tar.gz facter-59173268a5c6525a4a5df55b362775d07bc6b52d.tar.xz facter-59173268a5c6525a4a5df55b362775d07bc6b52d.zip |
Merge branch 'next'
* next: (32 commits)
(#7507) Fix 1.9.2 test failure
Removed inappropriately uncredited Ohai method from ec2 fact
(#6614) Update ipaddress6 fact to work with Ruby 1.9
(#6612) Changed uptime spec to be endian agnostic
(#6728) Facter improperly detects openvzve on CloudLinux systems
(#5135) Fix faulty logic in physicalprocessorcount
Ensures that ARP facts are returned only on EC2 hosts
Fixed #6974 - Moved to Apache 2.0 license
refactor the mechanism for allowing for resolution ordering to be influenced
(#6740) facter doesn't always respect facts in environment variables
Partial fix for #6971 - Fix for virtual tests
(#2714) Fixed faulty test
(#2714) Added timeout to prtdiag resulution
(#5135) Refactored physicalprocessorcount
Re-factor. Do not use pure-Ruby file reading against "/proc/cpuinfo" and possibly any entry under "/sys" from the sysfs file system.
Fix. Using sysfs file system entries to count the number of physical CPUs. Fall-back to "/proc/cpuinfo" included for backward-compatibility with legacy systems.
(#3856) Add virtualbox detection via lspci (graphics card), dmidecode, and prtdiag for Solaris and corresponding tests. Darwin case is not handled yet.
(#6883) Update Facter install.rb to be slightly more informative.
(#5394) Document each Facter fact.
(#6862) Add a default subject for the mail_patches rake task
...
Diffstat (limited to 'lib/facter/hardwaremodel.rb')
-rw-r--r-- | lib/facter/hardwaremodel.rb | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/lib/facter/hardwaremodel.rb b/lib/facter/hardwaremodel.rb index 6201bdd..8f52fef 100644 --- a/lib/facter/hardwaremodel.rb +++ b/lib/facter/hardwaremodel.rb @@ -1,3 +1,16 @@ +# Fact: hardwaremodel +# +# Purpose: +# Returns the hardware model of the system. +# +# Resolution: +# Uses purely "uname -m" on all platforms other than AIX and Windows. +# On AIX uses the parsed "modelname" output of "lsattr -El sys0 -a modelname". +# On Windows uses the 'host_cpu' pulled out of Ruby's config. +# +# Caveats: +# + Facter.add(:hardwaremodel) do setcode 'uname -m' end |