X-Git-Url: https://review.fuel-infra.org/gitweb?a=blobdiff_plain;f=lib%2Ffacter%2Fapt_updates.rb;h=77e667e6d76c18f8f2eed5adc3b2dad187035c32;hb=65a5a251101fc5c544099174b2133fcb9dfe529e;hp=75670bc39767280c0d8fbd2ddfa7121ded3ffe30;hpb=d090ae4ebb9041bc46e161f698732a6bc9d28399;p=puppet-modules%2Fpuppetlabs-apt.git diff --git a/lib/facter/apt_updates.rb b/lib/facter/apt_updates.rb index 75670bc..77e667e 100644 --- a/lib/facter/apt_updates.rb +++ b/lib/facter/apt_updates.rb @@ -2,7 +2,7 @@ apt_package_updates = nil Facter.add("apt_has_updates") do confine :osfamily => 'Debian' if File.executable?("/usr/lib/update-notifier/apt-check") - apt_package_updates = Facter::Util::Resolution.exec('/usr/lib/update-notifier/apt-check 2>&1').split(';') + apt_package_updates = Facter::Util::Resolution.exec('/usr/lib/update-notifier/apt-check 2>/dev/null').split(';') end setcode do @@ -13,7 +13,7 @@ end Facter.add("apt_package_updates") do confine :apt_has_updates => true setcode do - packages = Facter::Util::Resolution.exec('/usr/lib/update-notifier/apt-check -p 2>&1').split("\n") + packages = Facter::Util::Resolution.exec('/usr/lib/update-notifier/apt-check -p 2>/dev/null').split("\n") if Facter.version < '2.0.0' packages.join(',') else