diff --git a/qa/cephfs/begin/3-kernel.yaml b/qa/cephfs/begin/3-kernel.yaml new file mode 100644 index 00000000000000..685c744a71e71e --- /dev/null +++ b/qa/cephfs/begin/3-kernel.yaml @@ -0,0 +1,17 @@ +# When the --kernel option is given to teuthology-suite, the "default" kernel +# is set for all nodes. We don't generally want to use a custom kernel for all +# tests, so unset it. The k-testing.yaml will set it, if given, for only the +# client nodes. +# +# Allow overriding this by using a branch ending in "-all". + +teuthology: + postmerge: + - | + if not yaml.kernel.branch:find "-all$" then + log.debug("removing default kernel specification: %s", yaml.kernel) + py_attrgetter(yaml.kernel).pop('branch', nil) + py_attrgetter(yaml.kernel).pop('flavor', nil) + py_attrgetter(yaml.kernel).pop('kdb', nil) + py_attrgetter(yaml.kernel).pop('sha1', nil) + end diff --git a/qa/cephfs/mount/kclient/overrides/distro/testing/k-testing.yaml b/qa/cephfs/mount/kclient/overrides/distro/testing/k-testing.yaml index 2ee219125e7a7e..048cd5ce8b9049 100644 --- a/qa/cephfs/mount/kclient/overrides/distro/testing/k-testing.yaml +++ b/qa/cephfs/mount/kclient/overrides/distro/testing/k-testing.yaml @@ -1,3 +1,12 @@ +teuthology: + premerge: | + log.debug("base kernel %s", base_config.kernel) + local kernel = base_config.kernel + if kernel.branch ~= "distro" then + log.debug("overriding testing kernel with %s", kernel) + yaml_fragment.kernel.client = kernel + end + kernel: client: branch: testing