]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
Merge pull request #35141 from matthewoliver/cephadm_iscsi_lib_module_mount
authorSebastian Wagner <sebastian.wagner@suse.com>
Fri, 19 Jun 2020 11:21:13 +0000 (13:21 +0200)
committerGitHub <noreply@github.com>
Fri, 19 Jun 2020 11:21:13 +0000 (13:21 +0200)
cephadm: Give iscsci a RO /lib/modules bind mounted

Reviewed-by: Michael Fritch <mfritch@suse.com>
Reviewed-by: Sebastian Wagner <sebastian.wagner@suse.com>
1  2 
src/cephadm/cephadm

index 0cf359f58e438a2f6a43e665452518080fb70492,4b2c8b3a476e49e91aedaef4575815e23c7af9d4..7ff30248e9a873f4e2be9187b296af9e545976d2
@@@ -384,9 -378,20 +384,20 @@@ class CephIscsi(object)
          mounts['/dev/log'] = '/dev/log:z'
          return mounts
  
+     @staticmethod
+     def get_container_binds():
+         # type: () -> List[List[str]]
+         binds = []
+         lib_modules = ['type=bind',
+                        'source=/lib/modules',
+                        'destination=/lib/modules',
+                        'ro=true']
+         binds.append(lib_modules)
+         return binds
      @staticmethod
      def get_version(container_id):
 -        # type(str) -> Optional[str]
 +        # type(str) -> Optional[str]
          version = None
          out, err, code = call(
              [container_path, 'exec', container_id,