From: Melissa
Date: Wed, 21 Jul 2021 01:50:33 +0000 (-0400)
Subject: mgr/cephadm: remove _executable_path from module.py
X-Git-Tag: v17.1.0~1051^2~7
X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=b55eb2a386f0a53b55ec9511b9ea133c5f8fae0d;p=ceph.git
mgr/cephadm: remove _executable_path from module.py
Fixes: https://tracker.ceph.com/issues/44676
Signed-off-by: Melissa Li
---
diff --git a/src/pybind/mgr/cephadm/module.py b/src/pybind/mgr/cephadm/module.py
index 09ec70af7889..43b1ee050e98 100644
--- a/src/pybind/mgr/cephadm/module.py
+++ b/src/pybind/mgr/cephadm/module.py
@@ -1274,22 +1274,6 @@ class CephadmOrchestrator(orchestrator.Orchestrator, MgrModule,
return conn, r
- def _executable_path(self, conn: 'remoto.backends.BaseConnection', executable: str) -> str:
- """
- Remote validator that accepts a connection object to ensure that a certain
- executable is available returning its full path if so.
-
- Otherwise an exception with thorough details will be raised, informing the
- user that the executable was not found.
- """
- executable_path = conn.remote_module.which(executable)
- if not executable_path:
- raise RuntimeError("Executable '{}' not found on host '{}'".format(
- executable, conn.hostname))
- self.log.debug("Found executable '{}' at path '{}'".format(executable,
- executable_path))
- return executable_path
-
def _get_container_image(self, daemon_name: str) -> Optional[str]:
daemon_type = daemon_name.split('.', 1)[0] # type: ignore
image: Optional[str] = None