mirror of
https://bitbucket.org/atlassian-docker/docker-atlassian-confluence-server.git
synced 2024-08-30 18:22:16 +00:00
Fixed the set_perms chown operation that was not recursively setting permissions
This commit is contained in:
parent
bcaf05a3ab
commit
d2920dfc3c
@ -13,8 +13,12 @@ import jinja2 as j2
|
||||
logging.basicConfig(level=logging.DEBUG)
|
||||
|
||||
def set_perms(path, user, group, mode):
|
||||
shutil.chown(path, user=user, group=group)
|
||||
os.chmod(path, mode)
|
||||
for dirpath, dirnames, filenames in os.walk(path):
|
||||
shutil.chown(dirpath, user=user, group=group)
|
||||
os.chmod(dirpath, mode)
|
||||
for filename in filenames:
|
||||
shutil.chown(os.path.join(dirpath, filename), user=user, group=group)
|
||||
os.chmod(os.path.join(dirpath, filename), mode)
|
||||
|
||||
# Setup Jinja2 for templating
|
||||
jenv = j2.Environment(
|
||||
|
Loading…
Reference in New Issue
Block a user