]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
qa/tasks/ceph2: pull image using sha1
authorSage Weil <sage@redhat.com>
Fri, 15 Nov 2019 14:21:02 +0000 (14:21 +0000)
committerSage Weil <sage@redhat.com>
Thu, 21 Nov 2019 16:46:54 +0000 (10:46 -0600)
Signed-off-by: Sage Weil <sage@redhat.com>
qa/tasks/ceph2.py

index a4e9791fbb403c58492925223001cca490f65705..20c949ac1b3a1586b729d85603bf9f4f992bbed7 100644 (file)
@@ -758,12 +758,19 @@ def task(ctx, config):
     #validate_config(ctx, config)
 
     # image
-    branch = config.get('branch', 'master')
-    ### FIXME ###
-    if branch in ['master', 'nautilus']:
-        ctx.image = 'ceph/daemon-base:latest-%s-devel' % branch
-    else:
-        ctx.image = 'quay.io/ceph-ci/ceph:%s' % branch
+    ctx.image = config.get('image')
+    if not ctx.image:
+        sha1 = config.get('sha1')
+        if sha1:
+            ctx.image = 'quay.io/ceph-ci/ceph:%s' % sha1
+        else:
+            # hmm, fall back to branch?
+            branch = config.get('branch', 'master')
+            # FIXME when ceph-ci builds all branches
+            if branch in ['master', 'nautilus']:
+                ctx.image = 'ceph/daemon-base:latest-%s-devel' % branch
+            else:
+                ctx.image = 'quay.io/ceph-ci/ceph:%s' % branch
     log.info('Cluster image is %s' % ctx.image)
 
     # uuid