From ebfcc1e9ea32ff3ee06527346efd376802efb497 Mon Sep 17 00:00:00 2001 From: Deepak Sihag Date: Thu, 8 Dec 2022 08:45:57 -0800 Subject: [PATCH] systemd enable only if service is allowed `buildkite_agent_allow_service_startup` controls whether service should be started or not, but in case of `Debian` service is enabled in systemd, which leads to auto starts on reboots. Using same variable to control the systemd enable/disable as well. --- tasks/install-on-Debian.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tasks/install-on-Debian.yml b/tasks/install-on-Debian.yml index 4bf4baa..1bb8822 100644 --- a/tasks/install-on-Debian.yml +++ b/tasks/install-on-Debian.yml @@ -72,5 +72,5 @@ systemd: name: buildkite-agent state: '{{ buildkite_agent_allow_service_startup[ansible_os_family] | ternary(''started'', ''stopped'') }}' - enabled: true + enabled: '{{ buildkite_agent_allow_service_startup[ansible_os_family] }}' daemon_reload: true