From 270889bdec10b7804be21ebfa487eeedfd941e5e Mon Sep 17 00:00:00 2001 From: usman Date: Tue, 7 Sep 2021 19:38:30 +0500 Subject: [PATCH 1/2] bug fix: dkim manager --- cloudAPI/cloudManager.py | 9 +++++++++ mailServer/mailserverManager.py | 6 ++++++ plogical/dnsUtilities.py | 6 ++++++ plogical/mailUtilities.py | 3 +++ 4 files changed, 24 insertions(+) diff --git a/cloudAPI/cloudManager.py b/cloudAPI/cloudManager.py index 84e36e4e5..09b126c6b 100755 --- a/cloudAPI/cloudManager.py +++ b/cloudAPI/cloudManager.py @@ -2829,6 +2829,9 @@ class CloudManager: command = 'chown -R cyberpanel:cyberpanel /usr/local/CyberCP/lib/python3.8/site-packages/tldextract/.suffix_cache/' ProcessUtilities.executioner(command) + command = 'chown cyberpanel:cyberpanel /usr/local/CyberCP/lib/python3.8/site-packages/tldextract/.suffix_cache/publicsuffix.org-tlds/' + ProcessUtilities.executioner(command) + ## ipFile = "/etc/cyberpanel/machineIP" @@ -2846,6 +2849,9 @@ class CloudManager: command = 'chown cyberpanel:cyberpanel -R /usr/local/CyberCP/lib/python3.6/site-packages/tldextract/.suffix_cache' ProcessUtilities.executioner(command) + command = 'chown cyberpanel:cyberpanel /usr/local/CyberCP/lib/python3.8/site-packages/tldextract/.suffix_cache/publicsuffix.org-tlds/' + ProcessUtilities.executioner(command) + for website in Websites.objects.all(): import tldextract extractDomain = tldextract.extract(website.domain) @@ -2888,6 +2894,9 @@ class CloudManager: command = 'chown cyberpanel:cyberpanel -R /usr/local/CyberCP/lib/python3.6/site-packages/tldextract/.suffix_cache' ProcessUtilities.executioner(command) + command = 'chown cyberpanel:cyberpanel /usr/local/CyberCP/lib/python3.8/site-packages/tldextract/.suffix_cache/publicsuffix.org-tlds/' + ProcessUtilities.executioner(command) + from websiteFunctions.models import ChildDomains for website in ChildDomains.objects.all(): diff --git a/mailServer/mailserverManager.py b/mailServer/mailserverManager.py index 5a8f0b316..75685f35b 100755 --- a/mailServer/mailserverManager.py +++ b/mailServer/mailserverManager.py @@ -662,6 +662,9 @@ class MailServerManager(multi.Thread): command = 'chown cyberpanel:cyberpanel -R /usr/local/CyberCP/lib/python3.6/site-packages/tldextract/.suffix_cache' ProcessUtilities.executioner(command) + command = 'chown cyberpanel:cyberpanel /usr/local/CyberCP/lib/python3.8/site-packages/tldextract/.suffix_cache/publicsuffix.org-tlds/' + ProcessUtilities.executioner(command) + import tldextract extractDomain = tldextract.extract(domainName) @@ -724,6 +727,9 @@ class MailServerManager(multi.Thread): command = 'chown cyberpanel:cyberpanel -R /usr/local/CyberCP/lib/python3.6/site-packages/tldextract/.suffix_cache' ProcessUtilities.executioner(command) + command = 'chown cyberpanel:cyberpanel /usr/local/CyberCP/lib/python3.8/site-packages/tldextract/.suffix_cache/publicsuffix.org-tlds/' + ProcessUtilities.executioner(command) + import tldextract extractDomain = tldextract.extract(domainName) diff --git a/plogical/dnsUtilities.py b/plogical/dnsUtilities.py index 17bb25620..097644878 100755 --- a/plogical/dnsUtilities.py +++ b/plogical/dnsUtilities.py @@ -117,6 +117,9 @@ class DNS: command = 'chown cyberpanel:cyberpanel -R /usr/local/CyberCP/lib/python3.6/site-packages/tldextract/.suffix_cache' ProcessUtilities.executioner(command) + command = 'chown cyberpanel:cyberpanel /usr/local/CyberCP/lib/python3.8/site-packages/tldextract/.suffix_cache/publicsuffix.org-tlds/' + ProcessUtilities.executioner(command) + import tldextract extractDomain = tldextract.extract(domain) @@ -521,6 +524,9 @@ class DNS: command = 'chown cyberpanel:cyberpanel -R /usr/local/CyberCP/lib/python3.6/site-packages/tldextract/.suffix_cache' ProcessUtilities.executioner(command) + command = 'chown cyberpanel:cyberpanel /usr/local/CyberCP/lib/python3.8/site-packages/tldextract/.suffix_cache/publicsuffix.org-tlds/' + ProcessUtilities.executioner(command) + import tldextract extractDomain = tldextract.extract(domain) diff --git a/plogical/mailUtilities.py b/plogical/mailUtilities.py index 2ec0529cf..7abe0c82b 100755 --- a/plogical/mailUtilities.py +++ b/plogical/mailUtilities.py @@ -221,6 +221,9 @@ class mailUtilities: command = 'chown cyberpanel:cyberpanel -R /usr/local/CyberCP/lib/python3.6/site-packages/tldextract/.suffix_cache' ProcessUtilities.executioner(command) + command = 'chown cyberpanel:cyberpanel /usr/local/CyberCP/lib/python3.8/site-packages/tldextract/.suffix_cache/publicsuffix.org-tlds/' + ProcessUtilities.executioner(command) + import tldextract actualDomain = virtualHostName From 088ad7379e0d7ae4c5039e5ce3643842832344f5 Mon Sep 17 00:00:00 2001 From: Istiak Ferdous <30789544+istiak101@users.noreply.github.com> Date: Thu, 9 Sep 2021 01:20:11 +0600 Subject: [PATCH 2/2] Fix architecture detection Previously aarch64 would be detected as valid system while it is not yet supported. --- cyberpanel.sh | 4 ++-- cyberpanel_upgrade.sh | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/cyberpanel.sh b/cyberpanel.sh index 40d8bb431..ca12e6a51 100644 --- a/cyberpanel.sh +++ b/cyberpanel.sh @@ -253,8 +253,8 @@ else fi -if ! uname -m | grep -q 64 ; then - echo -e "x64 system is required...\n" +if ! uname -m | grep -q x86_64 ; then + echo -e "x86_64 system is required...\n" exit fi diff --git a/cyberpanel_upgrade.sh b/cyberpanel_upgrade.sh index ee15bb968..0e00cc637 100644 --- a/cyberpanel_upgrade.sh +++ b/cyberpanel_upgrade.sh @@ -108,8 +108,8 @@ if [[ ! -f /etc/os-release ]] ; then exit fi -if ! uname -m | grep -q 64 ; then - echo -e "x64 system is required...\n" +if ! uname -m | grep -q x86_64 ; then + echo -e "x86_64 system is required...\n" exit fi