summaryrefslogtreecommitdiffstats
path: root/src/sbin/bcfg2-repo-validate
diff options
context:
space:
mode:
Diffstat (limited to 'src/sbin/bcfg2-repo-validate')
-rwxr-xr-xsrc/sbin/bcfg2-repo-validate8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/sbin/bcfg2-repo-validate b/src/sbin/bcfg2-repo-validate
index 1d16a8148..685916fc9 100755
--- a/src/sbin/bcfg2-repo-validate
+++ b/src/sbin/bcfg2-repo-validate
@@ -54,6 +54,14 @@ if __name__ == '__main__':
included.add(ent)
included.discard(filename)
+ # check for multiple default group definitions
+ default_groups = lxml.etree.parse("%s/Metadata/groups.xml" \
+ % repo).findall('.//Group[@default="true"]')
+ if len(default_groups) > 1:
+ print("*** Warning: Multiple default groups defined")
+ for grp in default_groups:
+ print(" %s" % grp.get('name'))
+
# get all XIncluded bundles
xdata.xinclude()
for bundle in xdata.findall("//Bundle"):