]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
qa: install nvme-cli only if distro remains rocky10 69252/head
authorPatrick Donnelly <pdonnell@ibm.com>
Mon, 1 Jun 2026 15:37:23 +0000 (11:37 -0400)
committerPatrick Donnelly <pdonnell@ibm.com>
Tue, 2 Jun 2026 20:12:39 +0000 (16:12 -0400)
Notably, only include these the `dnf install` commands if the distro is
not overriden by some other mechanism (like cephfs kernel overrides).

This is only a problem for tentacle presently as the k-stock kernel will
override with centos9.

Fixes: https://tracker.ceph.com/issues/77037
Signed-off-by: Patrick Donnelly <pdonnell@ibm.com>
(cherry picked from commit 038383a2ffab063afdddb3d2084cfbdd49b99e31)

Conflicts:
qa/distros/all/rocky_10.yaml
Resolution: used `main` version

qa/distros/all/rocky_10.yaml

index b4e37502ea668e213c5f5552153d3c00501699f1..52627f5aeda09f577f76079d585f610db92bf2ed 100644 (file)
@@ -1,25 +1,31 @@
+install_rocky_packages:
+  sequential:
+    - print: "Install additional rocky10 dependencies"
+    # postmerge appends to this
 os_type: rocky
 os_version: "10.1"
 overrides:
   selinux:
     allowlist:
       - 'comm="systemd".*denied.*\{ prog_run \}.*tclass=bpf.*permissive=1'
+tasks:
+  # This is appended to the tasks: list here so that we can edit the task list
+  # before e.g. ceph is installed.
+  - sequential:
+      - install_rocky_packages
 teuthology:
   postmerge:
     - |
+      log.debug("os is %s", yaml.os_type)
       if yaml.os_type == 'rocky' then
         local pexec_tasks = yaml_load([[
-        - pexec:
-            all:
-            # for https://tracker.ceph.com/issues/73823
-            - sudo dnf remove nvme-cli -y
-            - sudo dnf install nvmetcli nvme-cli -y
+        sequential:
+          - pexec:
+              all:
+                # for https://tracker.ceph.com/issues/73823
+                # Cannot use install.extra_system_packages because we also remove a package.
+                - sudo dnf remove nvme-cli -y
+                - sudo dnf install nvmetcli nvme-cli -y
         ]])
-        
-        -- Ensure the tasks array exists before attempting to merge
-        if yaml.tasks == nil then
-          yaml.tasks = py_list()
-        end
-        
-        deep_merge(yaml.tasks, pexec_tasks)
+        deep_merge(yaml.install_rocky_packages, pexec_tasks)
       end