library/roles/nginx: Remove some old installed snipped that can conflict with the new ones.

This commit is contained in:
Andrea Dell'Amico 2016-10-03 18:27:39 +02:00
parent 4a54b1d96f
commit b32959ce2c
2 changed files with 7 additions and 0 deletions

View File

@ -16,6 +16,9 @@ nginx_conf_snippets:
- nginx-proxy-params.conf
- nginx-server-ssl.conf
nginx_old_snippets:
- compression.conf
nginx_workers: 4
nginx_worker_connections: 1024
nginx_multi_accept: 'off'

View File

@ -15,5 +15,9 @@
template: src=nginx.conf.j2 dest=/etc/nginx/nginx.conf mode=444
notify: Reload nginx
- name: Remove the old configuration snippets
file: dest=/etc/nginx/conf.d/{{ item }} state=absent
with_items: '{{ nginx_old_snippets }}'
when: nginx_enabled
tags: [ 'nginx', 'nginx_conf', 'nginx_virtualhost' ]