summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNarayan Desai <desai@mcs.anl.gov>2009-09-22 09:35:57 +0000
committerNarayan Desai <desai@mcs.anl.gov>2009-09-22 09:35:57 +0000
commit586dff26b60be8633dfb19601204329e152406e3 (patch)
treeefec4ff0c8e1c62a0b3c6e0c0a3b0130f95ad8c2
parented78f8df3edaab67f7fa8becd46360670e4ec99d (diff)
downloadbcfg2-586dff26b60be8633dfb19601204329e152406e3.tar.gz
bcfg2-586dff26b60be8633dfb19601204329e152406e3.tar.bz2
bcfg2-586dff26b60be8633dfb19601204329e152406e3.zip
Packages: Fix extra / inclusion in repomd urls (Resolves Ticket #740)
git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@5446 ce84e21b-d406-0410-9b95-82705330c041
-rw-r--r--src/lib/Server/Plugins/Packages.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/lib/Server/Plugins/Packages.py b/src/lib/Server/Plugins/Packages.py
index 6b581dd0d..c1924350b 100644
--- a/src/lib/Server/Plugins/Packages.py
+++ b/src/lib/Server/Plugins/Packages.py
@@ -205,7 +205,9 @@ class YUMSource(Source):
urls = []
for (sarch, surl_list) in surls:
for surl in surl_list:
- rmdurl = surl + '/repodata/repomd.xml'
+ if not surl.endswith('/'):
+ surl += '/'
+ rmdurl = surl + 'repodata/repomd.xml'
try:
repomd = urllib2.urlopen(rmdurl).read()
xdata = lxml.etree.XML(repomd)