ensure madmail daemon is enabled and started

This commit is contained in:
n8fr8 2026-05-08 06:17:27 -04:00
parent 5b418add4d
commit 0e3b1674f4

View file

@ -69,6 +69,14 @@ def run_madmail_installer():
child.sendline("y") child.sendline("y")
child.expect(pexpect.EOF) child.expect(pexpect.EOF)
daemon_enable = run(["sudo", "systemctl", "enable", "madmail"], capture_output=True, text=True)
if daemon_enable.returncode != 0:
print(f"Issue running systemctl daemon_enable")
daemon_start = run(["sudo", "systemctl", "start", "madmail"], capture_output=True, text=True)
if daemon_start.returncode != 0:
print(f"Issue running systemctl daemon_start")
daemon_reload = run(["sudo", "systemctl", "daemon-reload"], capture_output=True, text=True) daemon_reload = run(["sudo", "systemctl", "daemon-reload"], capture_output=True, text=True)
if daemon_reload.returncode != 0: if daemon_reload.returncode != 0:
print(f"Issue running systemctl daemon_reload") print(f"Issue running systemctl daemon_reload")