From 9e858dc55b76f46c12692a0a07f96bcbf45a9271 Mon Sep 17 00:00:00 2001 From: Mark Goddard Date: Mon, 29 May 2017 16:55:54 +0100 Subject: [PATCH] Small fixes for disable-glean role Don't stop glean services which are not loaded. --- ansible/roles/disable-glean/tasks/main.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ansible/roles/disable-glean/tasks/main.yml b/ansible/roles/disable-glean/tasks/main.yml index e1188166d..43f129fe4 100644 --- a/ansible/roles/disable-glean/tasks/main.yml +++ b/ansible/roles/disable-glean/tasks/main.yml @@ -1,6 +1,6 @@ --- - name: Check for existing Glean systemd services - command: systemctl list-units glean*.service --no-legend --no-pager + command: systemctl list-units glean*.service --no-legend --no-pager --state=loaded register: glean_services changed_when: False @@ -10,6 +10,7 @@ state: stopped enabled: no with_items: "{{ glean_services.stdout_lines }}" + become: True - name: Find interface configuration files created by Glean find: