]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
ceph-volume util make chown links affect links as well as paths 22716/head
authorAlfredo Deza <adeza@redhat.com>
Fri, 8 Jun 2018 12:54:07 +0000 (08:54 -0400)
committerSage Weil <sage@redhat.com>
Tue, 26 Jun 2018 11:42:29 +0000 (06:42 -0500)
Signed-off-by: Alfredo Deza <adeza@redhat.com>
(cherry picked from commit 7f79932f2c522da222a27c15182434914ca9a738)

src/ceph-volume/ceph_volume/util/system.py

index 0ba46d362766b3acb48e83f349f5ebf821912844..b4b7d17c4c946648e17c1548a7f53d961a65b3ba 100644 (file)
@@ -87,6 +87,7 @@ def chown(path, recursive=True):
     """
     uid, gid = get_ceph_user_ids()
     if os.path.islink(path):
+        process.run(['chown', '-h', 'ceph:ceph', path])
         path = os.path.realpath(path)
     if recursive:
         process.run(['chown', '-R', 'ceph:ceph', path])