From 00d7dd5777c656de79d8aad3762546e50ec21868 Mon Sep 17 00:00:00 2001 From: Michael Scherer Date: Mon, 4 Apr 2016 02:49:48 +0200 Subject: [PATCH] Move the unbound related handlers to the role --- handlers/restart_services.yml | 3 --- playbooks/groups/blockerbugs.yml | 1 - playbooks/groups/dhcp.yml | 1 - playbooks/groups/logserver.yml | 1 - playbooks/groups/memcached.yml | 1 - playbooks/groups/openstack-compute-nodes.yml | 1 - playbooks/groups/unbound.yml | 1 - playbooks/hosts/cloud-noc01.cloud.fedoraproject.org.yml | 1 - playbooks/hosts/data-analysis01.phx2.fedoraproject.org.yml | 1 - handlers/semanage.yml => roles/unbound/handlers/main.yml | 3 +++ 10 files changed, 3 insertions(+), 11 deletions(-) rename handlers/semanage.yml => roles/unbound/handlers/main.yml (78%) diff --git a/handlers/restart_services.yml b/handlers/restart_services.yml index 66f8335f6d..a2e96692fb 100644 --- a/handlers/restart_services.yml +++ b/handlers/restart_services.yml @@ -120,9 +120,6 @@ - name: restart network action: service name=network state=restarted -- name: restart unbound - action: service name=unbound state=restarted - - name: rebuild postfix transport command: /usr/sbin/postmap /etc/postfix/transport diff --git a/playbooks/groups/blockerbugs.yml b/playbooks/groups/blockerbugs.yml index 3916a988df..27d4b16f8c 100644 --- a/playbooks/groups/blockerbugs.yml +++ b/playbooks/groups/blockerbugs.yml @@ -33,4 +33,3 @@ handlers: - include: "{{ handlers }}/restart_services.yml" - - include: "{{ handlers }}/semanage.yml" diff --git a/playbooks/groups/dhcp.yml b/playbooks/groups/dhcp.yml index d0c34bb443..55f25723da 100644 --- a/playbooks/groups/dhcp.yml +++ b/playbooks/groups/dhcp.yml @@ -28,4 +28,3 @@ handlers: - include: "{{ handlers }}/restart_services.yml" - - include: "{{ handlers }}/semanage.yml" diff --git a/playbooks/groups/logserver.yml b/playbooks/groups/logserver.yml index 42cf474341..c045a30ee1 100644 --- a/playbooks/groups/logserver.yml +++ b/playbooks/groups/logserver.yml @@ -38,7 +38,6 @@ handlers: - include: "{{ handlers }}/restart_services.yml" - - include: "{{ handlers }}/semanage.yml" - name: Cloud Image stats hosts: log01.phx2.fedoraproject.org diff --git a/playbooks/groups/memcached.yml b/playbooks/groups/memcached.yml index b9593d5cd6..0e0fea21ee 100644 --- a/playbooks/groups/memcached.yml +++ b/playbooks/groups/memcached.yml @@ -28,4 +28,3 @@ handlers: - include: "{{ handlers }}/restart_services.yml" - - include: "{{ handlers }}/semanage.yml" diff --git a/playbooks/groups/openstack-compute-nodes.yml b/playbooks/groups/openstack-compute-nodes.yml index fee6967436..af154f695f 100644 --- a/playbooks/groups/openstack-compute-nodes.yml +++ b/playbooks/groups/openstack-compute-nodes.yml @@ -27,4 +27,3 @@ handlers: - include: "{{ handlers }}/restart_services.yml" - - include: "{{ handlers }}/semanage.yml" diff --git a/playbooks/groups/unbound.yml b/playbooks/groups/unbound.yml index 6e8c62801c..068c416040 100644 --- a/playbooks/groups/unbound.yml +++ b/playbooks/groups/unbound.yml @@ -29,4 +29,3 @@ handlers: - include: "{{ handlers }}/restart_services.yml" - - include: "{{ handlers }}/semanage.yml" diff --git a/playbooks/hosts/cloud-noc01.cloud.fedoraproject.org.yml b/playbooks/hosts/cloud-noc01.cloud.fedoraproject.org.yml index aa824a2e46..73fe45c9b4 100644 --- a/playbooks/hosts/cloud-noc01.cloud.fedoraproject.org.yml +++ b/playbooks/hosts/cloud-noc01.cloud.fedoraproject.org.yml @@ -28,5 +28,4 @@ handlers: - include: "{{ handlers }}/restart_services.yml" - - include: "{{ handlers }}/semanage.yml" diff --git a/playbooks/hosts/data-analysis01.phx2.fedoraproject.org.yml b/playbooks/hosts/data-analysis01.phx2.fedoraproject.org.yml index 0d0a6d1bef..102b0ccb3f 100644 --- a/playbooks/hosts/data-analysis01.phx2.fedoraproject.org.yml +++ b/playbooks/hosts/data-analysis01.phx2.fedoraproject.org.yml @@ -29,7 +29,6 @@ handlers: - include: "{{ handlers }}/restart_services.yml" - - include: "{{ handlers }}/semanage.yml" - name: dole out the service-specific config hosts: data-analysis01.phx2.fedoraproject.org diff --git a/handlers/semanage.yml b/roles/unbound/handlers/main.yml similarity index 78% rename from handlers/semanage.yml rename to roles/unbound/handlers/main.yml index bb9db3f6a9..e437eebe21 100644 --- a/handlers/semanage.yml +++ b/roles/unbound/handlers/main.yml @@ -1,3 +1,6 @@ +- name: restart unbound + action: service name=unbound state=restarted + - name: semanage dns80 command: /usr/sbin/semanage port -m -t dns_port_t -p tcp 80