diff --git a/nginx/tasks/nginx-config.yml b/nginx/tasks/nginx-config.yml index 5e7c5efc..2ae899cb 100644 --- a/nginx/tasks/nginx-config.yml +++ b/nginx/tasks/nginx-config.yml @@ -24,6 +24,7 @@ - name: Install the supported configuration snippets template: src={{ item }}.j2 dest=/etc/nginx/snippets/{{ item }} owner=root group=root mode=0444 with_items: '{{ nginx_conf_snippets }}' + notify: Reload nginx - name: Install the main nginx.conf template: src=nginx.conf.j2 dest=/etc/nginx/nginx.conf mode=444 @@ -32,6 +33,7 @@ - name: Remove the old configuration snippets file: dest=/etc/nginx/conf.d/{{ item }} state=absent with_items: '{{ nginx_old_snippets }}' + notify: Reload nginx when: nginx_enabled tags: [ 'nginx', 'nginx_conf', 'nginx_virtualhost' ]