From: Dmitriy Kruglov <
dmytro....@scylladb.com>
Committer: Valerii Ponomarov <
3796058+v...@users.noreply.github.com>
Branch: master
fix(manager-sanity-test): sync tls files to manager node
After rework of how TLS certificates and keys are created for each node in
SCT we cannot just copy the whole directory with TLS items from SCT runner instance
to a manager node. There are now dedicated subdirectories with certs/keys, one for each node,
which names are dynamically defined at runtime.
The change makes proper syncing of TLS files to manager node, instead of sending
the whole directory.
---
diff --git a/sdcm/cluster.py b/sdcm/cluster.py
--- a/sdcm/cluster.py
+++ b/sdcm/cluster.py
@@ -2284,10 +2284,10 @@ def install_mgmt(self, package_url: Optional[str] = None) -> None:
self.install_package(package_names)
self.log.debug("Create and send client TLS certificate/key to the node")
- self.create_node_certificate(self.ssl_conf_dir / TLSAssets.CLIENT_CERT,
- self.ssl_conf_dir / TLSAssets.CLIENT_KEY)
- self.remoter.send_files(
- str(self.ssl_conf_dir), dst='/tmp/ssl_conf')
+ self.create_node_certificate(cert_file=self.ssl_conf_dir / TLSAssets.CLIENT_CERT,
+ cert_key=self.ssl_conf_dir / TLSAssets.CLIENT_KEY)
+ self.remoter.run(f'mkdir -p {mgmt.cli.SSL_CONF_DIR}')
+ self.remoter.send_files(src=str(self.ssl_conf_dir) + '/', dst=str(mgmt.cli.SSL_CONF_DIR))
if self.is_docker():
try: