]> git-server-git.apps.pok.os.sepia.ceph.com Git - teuthology.git/commitdiff
suite: add --verify-ceph-hash <bool> option verify-ceph-hash
authorSage Weil <sage@newdream.net>
Fri, 12 Mar 2021 23:24:11 +0000 (17:24 -0600)
committerSage Weil <sage@newdream.net>
Fri, 12 Mar 2021 23:24:18 +0000 (17:24 -0600)
Sometimes we want to schedule a job without verifying that the
packages exist (or appear to exist) (e.g., because the container is
there and that's what the job is using).

Signed-off-by: Sage Weil <sage@newdream.net>
scripts/suite.py
teuthology/suite/run.py

index e826d57a3ec0b16d55af3de3db611f7a76a0bc19..3ab30f9a56cb46ab892dec89c6e6667323e06d4a 100644 (file)
@@ -86,6 +86,8 @@ Standard arguments:
   --validate-sha1 <bool>
                               Validate that git SHA1s passed to -S exist.
                               [default: true]
+  --verify-ceph-hash <bool>   Verify whether packages exist for the given hash
+                              [default: true]
   --sleep-before-teardown <seconds>
                               Number of seconds to sleep before teardown.
                               Use with care, as this applies to all jobs in the
index c980bc6909553650426723b2bd445b9093226179..e6d29285aee124d1143c33d7a499056a726d5015 100644 (file)
@@ -185,7 +185,7 @@ class Run(object):
         return ceph_hash
 
     def choose_ceph_version(self, ceph_hash):
-        if config.suite_verify_ceph_hash and not self.args.newest:
+        if self.args.verify_ceph_hash and config.suite_verify_ceph_hash and not self.args.newest:
             # don't bother if newest; we'll search for an older one
             # Get the ceph package version
             try:
@@ -443,7 +443,7 @@ class Run(object):
             )
 
             sha1 = self.base_config.sha1
-            if parsed_yaml.get('verify_ceph_hash',
+            if self.args.verify_ceph_hash and parsed_yaml.get('verify_ceph_hash',
                                config.suite_verify_ceph_hash):
                 full_job_config = copy.deepcopy(self.base_config.to_dict())
                 deep_merge(full_job_config, parsed_yaml)