a70c52c1d4
requirering the facter/util/debian.rb module causes puppet warnings on wheezy hosts, and custom facts like `$::debian_codename` cannot be evaluated. warning: Could not load fact file /srv/dev/projects/puppet/shared-modules//apt/lib/facter/debian_nextcodename.rb: no such file to load -- facter/util/debian Removing the require line solves this.
16 wiersze
312 B
Ruby
16 wiersze
312 B
Ruby
begin
|
|
require 'facter/util/debian'
|
|
rescue LoadError
|
|
require "#{File.dirname(__FILE__)}/util/debian"
|
|
end
|
|
|
|
Facter.add(:debian_lts) do
|
|
confine :operatingsystem => 'Debian'
|
|
setcode do
|
|
if Facter::Util::Debian::LTS.include? Facter.value('debian_codename')
|
|
true
|
|
else
|
|
false
|
|
end
|
|
end
|
|
end
|