From 4400bd70883ef1409d6500184f642b1f1bfd6294 Mon Sep 17 00:00:00 2001 From: Usman Nasir Date: Thu, 9 Apr 2020 00:10:53 +0500 Subject: [PATCH] bug fix: permissions --- filemanager/filemanager.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/filemanager/filemanager.py b/filemanager/filemanager.py index ef5ea7139..32b9aad41 100755 --- a/filemanager/filemanager.py +++ b/filemanager/filemanager.py @@ -525,13 +525,19 @@ class FileManager: ProcessUtilities.executioner(command) for childs in website.childdomains_set.all(): + command = "find %s -type d -exec chmod 0755 {} \;" % (childs.path) + ProcessUtilities.popenExecutioner(command) + + command = "find %s -type f -exec chmod 0644 {} \;" % (childs.path) + ProcessUtilities.popenExecutioner(command) + command = 'chown -R %s:%s %s/*' % (externalApp, externalApp, childs.path) ProcessUtilities.popenExecutioner(command) command = 'chown -R %s:%s %s/.[^.]*' % (externalApp, externalApp, childs.path) ProcessUtilities.popenExecutioner(command) - command = 'chmod 750 %s' % (childs.path) + command = 'chmod 755 %s' % (childs.path) ProcessUtilities.popenExecutioner(command) command = 'chmod %s:%s %s' % (externalApp, groupName, childs.path)