summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Sulfrian <alexander@sulfrian.net>2012-11-01 00:07:28 +0100
committerAlexander Sulfrian <alexander@sulfrian.net>2013-06-29 16:28:45 +0200
commitf3251794f53b3dee1b03d5f4e01a216c9030897b (patch)
tree9065149d1ddb1207781a0a37f1052361786e68de
parent05ac482e5906e62bb94e159e46270e21cd8c9a2a (diff)
downloadbcfg2-f3251794f53b3dee1b03d5f4e01a216c9030897b.tar.gz
bcfg2-f3251794f53b3dee1b03d5f4e01a216c9030897b.tar.bz2
bcfg2-f3251794f53b3dee1b03d5f4e01a216c9030897b.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`