]> git.apps.os.sepia.ceph.com Git - teuthology.git/commitdiff
install: prefer 'branch' over 'sha1'
authorSage Weil <sage@inktank.com>
Sun, 28 Apr 2013 16:35:45 +0000 (09:35 -0700)
committerSage Weil <sage@inktank.com>
Sun, 28 Apr 2013 16:35:45 +0000 (09:35 -0700)
The upgrade tasks specify 'branch' in the job file, but the
schedule_suite.sh script sets a sha1 in the overrides.  Make
the upgrade tests actually test an upgrade by preferring branch
over sha1 when both are specified.

This is fragile, but ought to do the trick for now!

Signed-off-by: Sage Weil <sage@inktank.com>
teuthology/task/install.py

index 4255bb09ca92853cf7b5e02e886013168ef7e288..8fd719577974ab820f032ad4b6d72ce73a2fa163 100644 (file)
@@ -50,12 +50,12 @@ def _get_baseurlinfo_and_dist(ctx, remote, config):
 
     uri = None
     log.info('config is %s', config)
-    if config.get('sha1') is not None:
-        uri = 'sha1/' + config.get('sha1')
-    elif config.get('tag') is not None:
+    if config.get('tag') is not None:
         uri = 'ref/' + config.get('tag')
     elif config.get('branch') is not None:
         uri = 'ref/' + config.get('branch')
+    elif config.get('sha1') is not None:
+        uri = 'sha1/' + config.get('sha1')
     else:
         uri = 'ref/master'
     retval['uri'] = uri