mirror of
https://github.com/usmannasir/cyberpanel.git
synced 2025-11-06 21:35:55 +01:00
bug fix: change ssh password for ubuntu
This commit is contained in:
@@ -2474,7 +2474,13 @@ StrictHostKeyChecking no
|
||||
|
||||
website = Websites.objects.get(domain=self.domain)
|
||||
|
||||
uBuntuPath = '/etc/lsb-release'
|
||||
|
||||
if os.path.exists(uBuntuPath):
|
||||
command = "echo '%s:%s' | chpasswd" % (data['externalApp'], data['password'])
|
||||
else:
|
||||
command = 'echo "%s" | passwd --stdin %s' % (data['password'], data['externalApp'])
|
||||
|
||||
ProcessUtilities.executioner(command)
|
||||
|
||||
data_ret = {'status': 1, 'error_message': 'None'}
|
||||
|
||||
Reference in New Issue
Block a user