bug fix: fix duplicate user issue that fallback to root

This commit is contained in:
Usman Nasir
2020-09-11 11:36:37 +05:00
parent bb94ee83b6
commit 2ce35a3073

View File

@@ -195,7 +195,7 @@ class WebsiteManager:
HA = data['HA']
externalApp = 'nobody'
except:
externalApp = "".join(re.findall("[a-zA-Z]+", domain))[:7]
externalApp = "".join(re.findall("[a-zA-Z]+", domain))[:5] + str(randint(1000, 9999))
@@ -223,14 +223,6 @@ class WebsiteManager:
import pwd
counter = 0
while 1:
try:
pwd.getpwnam(externalApp)
externalApp = '%s%s' % (externalApp, str(counter))
counter = counter + 1
except:
break
## Create Configurations
execPath = "/usr/local/CyberCP/bin/python " + virtualHostUtilities.cyberPanel + "/plogical/virtualHostUtilities.py"