]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
Merge PR #30827 into nautilus
authorPatrick Donnelly <pdonnell@redhat.com>
Thu, 14 Nov 2019 17:37:22 +0000 (09:37 -0800)
committerPatrick Donnelly <pdonnell@redhat.com>
Thu, 14 Nov 2019 17:37:22 +0000 (09:37 -0800)
* refs/pull/30827/head:
qa/tasks: tests for ls
mgr/volumes: list FS subvolumes, subvolume groups and their snapshots

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
1  2 
qa/tasks/cephfs/test_volumes.py
src/pybind/mgr/volumes/fs/subvolspec.py
src/pybind/mgr/volumes/fs/volume.py
src/pybind/mgr/volumes/module.py

Simple merge
index 56c5128a54cd503007ceee203994cc9e49202e4a,d00c1e4b1352b77feb87e1be599356cc6638118a..6c7df559129671f24b1dcd021c086d64edacc1f0
@@@ -90,13 -90,25 +90,25 @@@ class SubvolumeSpec(object)
          """
          return the subvolume snapshot path for a given snapshot name
          """
 -        return os.path.join(self.subvolume_path, snapdir, snapname)
 +        return os.path.join(self.subvolume_path, snapdir.encode('utf-8'), snapname.encode('utf-8'))
  
+     def make_subvol_snapdir_path(self, snapdir):
+         """
+         return the subvolume snapdir path
+         """
+         return os.path.join(self.subvolume_path, snapdir.encode('utf-8'))
      def make_group_snap_path(self, snapdir, snapname):
          """
          return the group snapshot path for a given snapshot name
          """
 -        return os.path.join(self.group_path, snapdir, snapname)
 +        return os.path.join(self.group_path, snapdir.encode('utf-8'), snapname.encode('utf-8'))
  
+     def make_group_snapdir_path(self, snapdir):
+         """
+         return the group's snapdir path
+         """
+         return os.path.join(self.group_path, snapdir.encode('utf-8'))
      def __str__(self):
          return "{0}/{1}".format(self.groupid, self.subvolumeid)
Simple merge
index 5de353ca6800468df952606bdff74017f835ec87,e44574c85773df09469f7c8bcec2f8d32a03beb7..0e710cfd5fc46c9a2d883dafdfc360ea8a2ccdb1
@@@ -37,11 -37,16 +37,17 @@@ class Module(orchestrator.OrchestratorC
          },
          {
              'cmd': 'fs volume rm '
 -                   'name=vol_name,type=CephString',
 -            'desc': "Delete a CephFS volume",
 +                   'name=vol_name,type=CephString '
 +                   'name=yes-i-really-mean-it,type=CephString,req=false ',
 +            'desc': "Delete a FS volume by passing --yes-i-really-mean-it flag",
              'perm': 'rw'
          },
+         {
+             'cmd': 'fs subvolumegroup ls '
+             'name=vol_name,type=CephString ',
+             'desc': "List subvolumegroups",
+             'perm': 'r'
+         },
          {
              'cmd': 'fs subvolumegroup create '
                     'name=vol_name,type=CephString '