]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
qa/tasks: pass testdir path to smb workunit
authorJohn Mulligan <jmulligan@redhat.com>
Mon, 29 Jun 2026 18:24:44 +0000 (14:24 -0400)
committerJohn Mulligan <jmulligan@redhat.com>
Sat, 11 Jul 2026 14:38:31 +0000 (10:38 -0400)
Ensure that the testdir (parent dir of generated tls certs)
is made available to the smb test configuration used by
the workunit tests.

Signed-off-by: John Mulligan <jmulligan@redhat.com>
qa/tasks/smb.py

index 691b33677e16e87a84819bd69251acc89fd799ac..f724a471b18c2cc222e3117ee8f57633fee03b6d 100644 (file)
@@ -349,6 +349,7 @@ def _workunit_commands(
 def workunit(ctx, config):
     """Workunit wrapper with special behaviors for smb."""
     from . import workunit
+    from teuthology import misc
 
     _config = copy.deepcopy(config)
     clients = _config.get('clients') or {}
@@ -375,6 +376,7 @@ def workunit(ctx, config):
     )
     _ssh_keys_config = config.get('ssh_keys', {})
     _config['enable_ssh_keys'] = _ssh_keys_config not in (False, None)
+    _config['testdir'] = misc.get_testdir(ctx)
     log.info('Passing workunit config: %r', _config)
     with contextlib.ExitStack() as estack:
         if _config['enable_ssh_keys']:
@@ -415,6 +417,8 @@ def write_metadata_file(ctx, config, *, roles=None):
             _node_info(ctx, node, client_name=node)
             for node in config.get('clients')
         ]
+    if config.get('testdir'):
+        obj['testdir'] = config['testdir']
     data = json.dumps(obj)
     log.debug('smb metadata: %r', obj)