From e17cb201233d9698241b103c5da39cd8d42b1770 Mon Sep 17 00:00:00 2001 From: Kevin Veen-Birkenbach Date: Thu, 14 Dec 2023 22:07:17 +0100 Subject: [PATCH] prevent freezer from stopping defrost timer --- .../files/system-maintenance-service-freezer.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/roles/system-maintenance-service-freezer/files/system-maintenance-service-freezer.py b/roles/system-maintenance-service-freezer/files/system-maintenance-service-freezer.py index 7bca9290..800e4913 100644 --- a/roles/system-maintenance-service-freezer/files/system-maintenance-service-freezer.py +++ b/roles/system-maintenance-service-freezer/files/system-maintenance-service-freezer.py @@ -51,6 +51,8 @@ def stop_timer(service): """ Stop and disable a systemd timer for a service if it exists. """ + if service == "system-maintenance-service-defrost": + print(f"Ignoring {service}. It's the initializer of freezer.") if service_file_exists(service, "timer"): timer_name = f"{service}.timer" subprocess.run(['systemctl', 'stop', timer_name])