WIP: Do not pre-filter based on environment

This commit is contained in:
Kienan Stewart 2022-09-02 09:58:07 -04:00
parent 32bb734f56
commit a90aba4365
1 changed files with 3 additions and 1 deletions

View File

@ -31,7 +31,9 @@ class Puppet::Resource::Redis < Puppet::Indirector::REST
# #
key = "catalog_#{host}_#{environment}" key = "catalog_#{host}_#{environment}"
resources = [] resources = []
keys = redis.keys("catalog_*_#{environment}") # With puppetdb, resources are picked up regardless of environment,
# and the user may choose to filter or not in the collector.
keys = redis.keys("catalog_*")
keys.each do |k| keys.each do |k|
next if k == key next if k == key
catalog = JSON.parse(redis.get(k)) catalog = JSON.parse(redis.get(k))