]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
ceph-volume simple.scan skip directories to scan
authorAlfredo Deza <adeza@redhat.com>
Wed, 8 Nov 2017 14:09:06 +0000 (09:09 -0500)
committerAlfredo Deza <adeza@redhat.com>
Thu, 9 Nov 2017 11:47:43 +0000 (06:47 -0500)
Signed-off-by: Alfredo Deza <adeza@redhat.com>
src/ceph-volume/ceph_volume/devices/simple/scan.py

index d83cc3c42d3994176e70e7ad7cdbc3ee5991c628..df916e73ea09292863257206d8327c53df802b6f 100644 (file)
@@ -66,6 +66,8 @@ class Scan(object):
             file_path = os.path.join(path, _file)
             if os.path.islink(file_path):
                 osd_metadata[_file] = self.scan_device(file_path)
+            if os.path.isdir(file_path):
+                continue
             # the check for binary needs to go before the file, to avoid
             # capturing data from binary files but still be able to capture
             # contents from actual files later