mirror of
https://github.com/usmannasir/cyberpanel.git
synced 2025-11-09 23:06:16 +01:00
Watchdog updated to include Dovecot, Postfix, PowerDNS, and Pure-FTPd
This commit is contained in:
@@ -139,7 +139,10 @@ def saveStatus(request):
|
||||
|
||||
if service == 'powerdns':
|
||||
|
||||
servicePath = '/home/cyberpanel/powerdns'
|
||||
if status == True:
|
||||
writeToFile = open(servicePath, 'w+')
|
||||
writeToFile.close()
|
||||
|
||||
pdns = PDNSStatus.objects.get(pk=1)
|
||||
pdns.serverStatus = 1
|
||||
@@ -200,6 +203,11 @@ def saveStatus(request):
|
||||
command = 'sudo systemctl disable pdns'
|
||||
ProcessUtilities.executioner(command)
|
||||
|
||||
try:
|
||||
os.remove(servicePath)
|
||||
except:
|
||||
pass
|
||||
|
||||
|
||||
elif service == 'postfix':
|
||||
|
||||
|
||||
Reference in New Issue
Block a user