]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr/rook: add StorageV1Api to RookOrchestrator
authorJoseph Sawaya <jsawaya@redhat.com>
Wed, 30 Jun 2021 20:18:33 +0000 (16:18 -0400)
committerJoseph Sawaya <jsawaya@redhat.com>
Tue, 13 Jul 2021 17:55:05 +0000 (13:55 -0400)
This commit adds the Kubernetes Python client StorageV1Api to the
RookOrchestrator Class.

Signed-off-by: Joseph Sawaya <jsawaya@redhat.com>
src/pybind/mgr/rook/module.py

index f78141c650b427ddf6f7e1b4709c153f67472f5b..d0df716f82c72d8e772ded7638009fc8004c0d44 100644 (file)
@@ -109,6 +109,7 @@ class RookOrchestrator(MgrModule, orchestrator.Orchestrator):
         self._k8s_CoreV1_api: Optional[client.CoreV1Api] = None
         self._k8s_BatchV1_api: Optional[client.BatchV1Api] = None
         self._k8s_CustomObjects_api: Optional[client.CustomObjectsApi] = None
+        self._k8s_StorageV1_api: Optional[client.StorageV1Api] = None
         self._rook_cluster: Optional[RookCluster] = None
         self._rook_env = RookEnv()
         self.storage_class_name = self.get_module_option('storage_class_name')
@@ -164,6 +165,7 @@ class RookOrchestrator(MgrModule, orchestrator.Orchestrator):
         self._k8s_CoreV1_api = client.CoreV1Api()
         self._k8s_BatchV1_api = client.BatchV1Api()
         self._k8s_CustomObjects_api = client.CustomObjectsApi()
+        self._k8s_StorageV1_api = client.StorageV1Api()
 
         try:
             # XXX mystery hack -- I need to do an API call from