From 4548da074b4da282e0daf4f61ec9108872e330b6 Mon Sep 17 00:00:00 2001 From: Lukas Bednar Date: Tue, 18 Jul 2017 13:16:04 +0200 Subject: [PATCH] ovirt-guest-agent: remove variable from handler name (#135) It fails for different value from defaults --- roles/ovirt-guest-agent/README.md | 2 +- roles/ovirt-guest-agent/handlers/main.yaml | 5 +++-- roles/ovirt-guest-agent/tasks/main.yml | 2 +- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/roles/ovirt-guest-agent/README.md b/roles/ovirt-guest-agent/README.md index cd45874..22c5707 100644 --- a/roles/ovirt-guest-agent/README.md +++ b/roles/ovirt-guest-agent/README.md @@ -21,7 +21,7 @@ Role Variables ```yaml --- -ovirt_guest_agent_pkg_prefix: "ovirt|rhevm|qemu" +ovirt_guest_agent_pkg_prefix: "ovirt|rhevm" ``` Default value if variable not given is ```ovirt```. diff --git a/roles/ovirt-guest-agent/handlers/main.yaml b/roles/ovirt-guest-agent/handlers/main.yaml index 4db354d..5b04c6c 100644 --- a/roles/ovirt-guest-agent/handlers/main.yaml +++ b/roles/ovirt-guest-agent/handlers/main.yaml @@ -1,6 +1,7 @@ --- -- name: enable and start {{ ovirt_guest_agent_pkg_prefix }}-guest-agent +- name: enable and start guest-agent service service: - name: "{{ ovirt_guest_agent_pkg_prefix }}-guest-agent" + # Name of service is same for both packages (ovirt/rhevm) + name: "ovirt-guest-agent" state: started enabled: yes diff --git a/roles/ovirt-guest-agent/tasks/main.yml b/roles/ovirt-guest-agent/tasks/main.yml index 5d0918f..504c9ed 100644 --- a/roles/ovirt-guest-agent/tasks/main.yml +++ b/roles/ovirt-guest-agent/tasks/main.yml @@ -4,6 +4,6 @@ state: latest with_items: - "{{ ovirt_guest_agent_pkg_prefix }}-guest-agent" - notify: enable and start {{ ovirt_guest_agent_pkg_prefix }}-guest-agent + notify: enable and start guest-agent service tags: - skip_ansible_lint