summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Sulfrian <alexander@sulfrian.net>2012-11-01 00:07:28 +0100
committerAlexander Sulfrian <alexander@sulfrian.net>2013-11-22 11:37:49 +0100
commitc1de77332dee33bf22f8305567fe6582a366788b (patch)
tree8c0456c4a2a6b38547e8c0ed04fce3caf915f440
parent7d4f1ba69c541cb649101e40527200b8e2a0051a (diff)
downloadbcfg2-c1de77332dee33bf22f8305567fe6582a366788b.tar.gz
bcfg2-c1de77332dee33bf22f8305567fe6582a366788b.tar.bz2
bcfg2-c1de77332dee33bf22f8305567fe6582a366788b.zip
Packages: add name to sources
-rw-r--r--schemas/packages.xsd9
-rw-r--r--src/lib/Bcfg2/Server/Plugins/Packages/Source.py3
2 files changed, 12 insertions, 0 deletions
diff --git a/schemas/packages.xsd b/schemas/packages.xsd
index 0fd3f6647..be8595fe2 100644
--- a/schemas/packages.xsd
+++ b/schemas/packages.xsd
@@ -221,6 +221,15 @@
</xsd:documentation>
</xsd:annotation>
</xsd:attribute>
+ <xsd:attribute type="xsd:string" name="name">
+ <xsd:annotation>
+ <xsd:documentation>
+ The name of the source to refer to that specify source
+ for specific packages. It could be used like pinning under
+ debian.
+ </xsd:documentation>
+ </xsd:annotation>
+ </xsd:attribute>
</xsd:complexType>
<xsd:complexType name="PackagesGroupType">
diff --git a/src/lib/Bcfg2/Server/Plugins/Packages/Source.py b/src/lib/Bcfg2/Server/Plugins/Packages/Source.py
index 01f2a732f..cbe45148b 100644
--- a/src/lib/Bcfg2/Server/Plugins/Packages/Source.py
+++ b/src/lib/Bcfg2/Server/Plugins/Packages/Source.py
@@ -212,6 +212,9 @@ class Source(Bcfg2.Server.Plugin.Debuggable): # pylint: disable=R0902
#: The "priority" attribute from :attr:`xsource`
self.priority = xsource.get('priority', 500)
+ #: The "name" attribute from :attr:`xsource`
+ self.name = xsource.get('name', '')
+
#: A list of predicates that are used to determine if this
#: source applies to a given
#: :class:`Bcfg2.Server.Plugins.Metadata.ClientMetadata`