puppetlabs-toy-chest / puppetlabs-package_updates

Package update discovery Puppet Face and custom Facter fact
12 stars 6 forks source link

Package providers returned in package_updates fact #19

Closed slauger closed 8 years ago

slauger commented 8 years ago

Hi,

first of all: thank you for this great module. I have been looking for something like this for a very long time.

I see an entry for each package_provider (that has available updates) in the package_update fact. Is this expected or a bug?

Example:

curl -q -X POST http://puppetdb:8080/pdb/query/v4/facts \
  -H 'Content-Type:application/json' \
  -d '{"query":["and", ["=", "name", "package_updates"], ["=", "environment", "production"]]}'
....
      "polkit": {
        "current": "0.112-5.el7",
        "name": "polkit",
        "provider": "yum",
        "update": "0:0.112-6.el7_2"
      }
....
      "yum": {}, # <--
       "puppet_gem": {}, # <--
ccaum commented 8 years ago

That behavior is intended. The fact works by collecting updates for every Puppet package provider on the system. If you'd like to filter out providers you don't care about, you can specify a filter in your PuppetDB query.

ccaum commented 8 years ago

I'm going to close this. If you have further feedback on the issue, let me know and I'll reopen.