summaryrefslogtreecommitdiffstats
path: root/lib/facter/util/virtual.rb
diff options
context:
space:
mode:
authorJames Turnbull <james@lovedthanlost.net>2010-04-24 15:42:37 +1000
committerJames Turnbull <james@lovedthanlost.net>2010-04-24 15:42:37 +1000
commit84d3d9f2abbe1f1a113103fe92d7fac39b734c9d (patch)
treed676c3babcc4dad7bd42d10285835f58fc2bea88 /lib/facter/util/virtual.rb
parentb5a8de0e8f4583c27d776cabe7686f41edb552fb (diff)
downloadfacter-84d3d9f2abbe1f1a113103fe92d7fac39b734c9d.tar.gz
facter-84d3d9f2abbe1f1a113103fe92d7fac39b734c9d.tar.xz
facter-84d3d9f2abbe1f1a113103fe92d7fac39b734c9d.zip
Fixed #3445 - Facter does not handle solaris branded zones properly
Thanks to Pavol Dilung for the fix.
Diffstat (limited to 'lib/facter/util/virtual.rb')
-rw-r--r--lib/facter/util/virtual.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/facter/util/virtual.rb b/lib/facter/util/virtual.rb
index ca7c367..80f4e2c 100644
--- a/lib/facter/util/virtual.rb
+++ b/lib/facter/util/virtual.rb
@@ -13,6 +13,7 @@ module Facter::Util::Virtual
end
def self.zone?
+ return true if FileTest.directory?("/.SUNWnative")
z = Facter::Util::Resolution.exec("/sbin/zonename")
return false unless z
return z.chomp != 'global'