]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr/cephadm: remove _executable_path from module.py
authorMelissa <li.melissa.kun@gmail.com>
Wed, 21 Jul 2021 01:50:33 +0000 (21:50 -0400)
committerMelissa Li <li.melissa.kun@gmail.com>
Fri, 20 Aug 2021 18:27:45 +0000 (14:27 -0400)
Fixes: https://tracker.ceph.com/issues/44676
Signed-off-by: Melissa Li <li.melissa.kun@gmail.com>
src/pybind/mgr/cephadm/module.py

index 09ec70af788998bcb988a0c2076680fa6cceee2e..43b1ee050e98f60b9b79863628d003111799f2ec 100644 (file)
@@ -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