From 8a0e495fa83dbaf0c8a3781049240b043ca1287e Mon Sep 17 00:00:00 2001 From: Matthew Grecar Date: Mon, 3 Dec 2018 04:15:24 -0500 Subject: [PATCH] Move service creation from install to configure (#57) [patch] --- tasks/configure.yml | 10 ++++++++++ tasks/install.yml | 10 ---------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/tasks/configure.yml b/tasks/configure.yml index 983a705..0b63634 100644 --- a/tasks/configure.yml +++ b/tasks/configure.yml @@ -10,3 +10,13 @@ validate: "/usr/local/bin/amtool --alertmanager.url= check-config %s" notify: - restart alertmanager + +- name: create systemd service unit + template: + src: alertmanager.service.j2 + dest: /etc/systemd/system/alertmanager.service + owner: root + group: root + mode: 0644 + notify: + - restart alertmanager diff --git a/tasks/install.yml b/tasks/install.yml index da744ba..ceb6750 100644 --- a/tasks/install.yml +++ b/tasks/install.yml @@ -52,16 +52,6 @@ notify: - restart alertmanager -- name: create systemd service unit - template: - src: alertmanager.service.j2 - dest: /etc/systemd/system/alertmanager.service - owner: root - group: root - mode: 0644 - notify: - - restart alertmanager - - name: Install SELinux dependencies on RedHat OS family package: name: "{{ item }}"