]> git.apps.os.sepia.ceph.com Git - teuthology.git/commitdiff
suite: allow override architecture
authorKyr Shatskyy <kyrylo.shatskyy@suse.com>
Sun, 10 May 2020 14:45:09 +0000 (16:45 +0200)
committerKyr Shatskyy <kyrylo.shatskyy@suse.com>
Mon, 6 Jul 2020 16:38:31 +0000 (18:38 +0200)
By default for generation job configuration and filtering
them out there is 'arch' field is used determined automatically
via request to paddles database for give machine_type.

This makes it possible to override the 'arch' value with
teuthology-suite '--arch' parameter. This is only useful
at the moment just when a user don't one to make any request
to paddles.
Originally the arch is used to filter out the suites
which are not supposed to be queued on the given nodes.

In future we probably need to have tests with heterogeneous
configuration which will use multiple architectures.

Signed-off-by: Kyr Shatskyy <kyrylo.shatskyy@suse.com>
scripts/suite.py
teuthology/suite/run.py

index 5805ec9a2bd5ccbc160b72adf7d2adbaa6ac5ec8..59036f5992b7bf2fda2a62a293042ad49e596586 100644 (file)
@@ -96,6 +96,10 @@ Standard arguments:
                               of resources, however --non-interactive option
                               can be used to skip user input.
                               [default: 0]
+  --arch <arch>               Override architecture defaults, for example,
+                              aarch64, armv7l, x86_64. Normally this
+                              argument should not be provided and the arch
+                              is determined from --machine-type.
 
 Scheduler arguments:
   --owner <owner>             Job owner
index e63fb562bb21e6d02d423c8f0020b49d2f0113d7..1a71404b1339cf5edb01f23df4668e477985834a 100644 (file)
@@ -498,7 +498,11 @@ class Run(object):
         Schedule the suite-run. Returns the number of jobs scheduled.
         """
         name = self.name
-        arch = util.get_arch(self.base_config.machine_type)
+        if self.args.arch:
+            arch = self.args.arch
+            log.debug("Using '%s' as an arch" % arch)
+        else:
+            arch = util.get_arch(self.base_config.machine_type)
         suite_name = self.base_config.suite
         suite_path = os.path.normpath(os.path.join(
             self.suite_repo_path,