summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDmitri Iouchtchenko <johnnyspoon@gmail.com>2017-03-17 14:32:55 -0400
committerDmitri Iouchtchenko <johnnyspoon@gmail.com>2017-03-17 14:32:55 -0400
commit80fd45128f0670897342c849100d84321aaa1ec4 (patch)
treeb7ef58e9d5d33c5c1b9587c6c647e651bcd744ae
parent9cba60eddee3e01830b0b0941e2b70b32bd9d4ed (diff)
downloadbcfg2-80fd45128f0670897342c849100d84321aaa1ec4.tar.gz
bcfg2-80fd45128f0670897342c849100d84321aaa1ec4.tar.bz2
bcfg2-80fd45128f0670897342c849100d84321aaa1ec4.zip
Server/Lint: Include RequiredBundle in referenced bundles
-rw-r--r--src/lib/Bcfg2/Server/Lint/Bundler.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/lib/Bcfg2/Server/Lint/Bundler.py b/src/lib/Bcfg2/Server/Lint/Bundler.py
index 576e157ad..7b024229b 100644
--- a/src/lib/Bcfg2/Server/Lint/Bundler.py
+++ b/src/lib/Bcfg2/Server/Lint/Bundler.py
@@ -29,8 +29,12 @@ class Bundler(ServerPlugin):
# when given a list of files on stdin, this check is
# useless, so skip it
groupdata = self.metadata.groups_xml.xdata
+
ref_bundles = set([b.get("name")
for b in groupdata.findall("//Bundle")])
+ for bundle in self.core.plugins['Bundler'].bundles.values():
+ ref_bundles |= set([rb.get("name") for rb in
+ bundle.xdata.findall(".//RequiredBundle")])
allbundles = self.core.plugins['Bundler'].bundles.keys()
for bundle in ref_bundles: