Signed-off-by: Michael Kincaid <[email protected]>
---
Local-branch: ticket/next/3856
 lib/facter/virtual.rb |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/facter/virtual.rb b/lib/facter/virtual.rb
index a583995..3cb5b42 100644
--- a/lib/facter/virtual.rb
+++ b/lib/facter/virtual.rb
@@ -16,12 +16,11 @@
 #   contents of files in there.
 #   If after all the other tests, it's still seen as physical, then it tries to
 #   parse the output of the "lspci", "dmidecode" and "prtdiag" and parses them
-#   for obvious signs of being under VMWare or Parallels.
+#   for obvious signs of being under VMWare, Parallels or VirtualBox.
 #   Finally it checks for the existence of vmware-vmx, which would hint it's
 #   VMWare.
 #
 # Caveats:
-#   Virtualbox detection isn't implemented. 
 #   Many checks rely purely on existence of files.
 #
 
@@ -39,6 +38,7 @@ Facter.add("virtual") do
             result = "parallels" if output["spdisplays_vendor"] =~ 
/[Pp]arallels/
             result = "vmware" if output["spdisplays_vendor-id"] =~ /0x15ad/
             result = "vmware" if output["spdisplays_vendor"] =~ /VM[wW]are/
+            result = "virtualbox" if output["spdisplays_vendor-id"] =~ /0x80ee/
         end
         result
     end
-- 
1.7.4.1

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Developers" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/puppet-dev?hl=en.

Reply via email to