From 0e3b1674f417073ac2d88bb97bfa2df64b795fe4 Mon Sep 17 00:00:00 2001 From: n8fr8 Date: Fri, 8 May 2026 06:17:27 -0400 Subject: [PATCH] ensure madmail daemon is enabled and started --- install_madmail.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/install_madmail.py b/install_madmail.py index 626bc71..c71ea50 100644 --- a/install_madmail.py +++ b/install_madmail.py @@ -69,6 +69,14 @@ def run_madmail_installer(): child.sendline("y") 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) if daemon_reload.returncode != 0: print(f"Issue running systemctl daemon_reload")