Notify to reload nginx configuration
This commit is contained in:
parent
2c18439948
commit
27438ee8db
|
@ -43,7 +43,7 @@
|
|||
path: "{{ item.path }}"
|
||||
state: absent
|
||||
with_items: "{{ vhost_to_delete.files }}"
|
||||
notify: systemctl restart nginx
|
||||
notify: systemctl reload nginx
|
||||
|
||||
- name: add vhost configuration sylink for {{ item.servername }}
|
||||
file:
|
||||
|
@ -51,7 +51,7 @@
|
|||
dest: "/etc/nginx/sites-enabled/{{ item.servername }}.vhost"
|
||||
state: link
|
||||
with_items: "{{ nginx_vhosts }}"
|
||||
notify: systemctl restart nginx
|
||||
notify: systemctl reload nginx
|
||||
|
||||
- name: add logrotate configuration for {{ item.servername }}
|
||||
template:
|
||||
|
|
|
@ -34,6 +34,7 @@
|
|||
path: /etc/nginx/nginx.conf
|
||||
regexp: "^(.*)ssl_protocols"
|
||||
line: "\tssl_protocols TLSv1.2 TLSv1.3;"
|
||||
notify: systemctl reload nginx
|
||||
|
||||
- name: gzip compression
|
||||
lineinfile:
|
||||
|
@ -46,6 +47,7 @@
|
|||
line: "\tgzip_comp_level 5;"
|
||||
- regexp: "^(.*)gzip_types"
|
||||
line: "\tgzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript;"
|
||||
notify: systemctl reload nginx
|
||||
|
||||
|
||||
- import_tasks: create-vhosts.yml
|
||||
|
|
Loading…
Reference in a new issue