Update operatingsystem fact to support Sabayon the official way
This commit is contained in:
@@ -1,11 +1,13 @@
|
|||||||
Facter.add(:operatingsystem) do
|
Facter.add(:operatingsystem) do
|
||||||
confine :kernel => :linux
|
# Sabayon Linux is a variant of Gentoo so this resolution needs to come
|
||||||
confine :has_entropy => true
|
# before the Gentoo resolution.
|
||||||
|
has_weight(10)
|
||||||
|
confine :kernel => :linux
|
||||||
|
|
||||||
setcode do
|
setcode do
|
||||||
if FileTest.exists?("/etc/sabayon-release")
|
release_info = Facter::Util::Operatingsystem.os_release
|
||||||
"Sabayon"
|
if release_info['NAME'] == "Sabayon"
|
||||||
end
|
'Sabayon'
|
||||||
end
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user