Flush handlers before running nginx -T and setting up logrotate (#279)

This commit is contained in:
Alessandro Fael Garcia 2020-07-07 10:44:13 +02:00 committed by GitHub
parent a0a49176a3
commit 7341b2ec64
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 11 additions and 11 deletions

View File

@ -33,9 +33,6 @@
dest: "/etc/logrotate.d/nginx"
register: nginx_logrotate_result
- name: "(Config: All OSs) Ensure NGINX is Running"
meta: flush_handlers
- name: "(Config: All OSs) Run Logrotate"
command: logrotate -f /etc/logrotate.d/nginx
changed_when: nginx_logrotate_result.changed

View File

@ -53,16 +53,23 @@
when: true in nginx_modules.values()
tags: nginx_install_modules
- include_tasks: "{{ role_path }}/tasks/conf/debug-output.yml"
when: nginx_debug_output | bool
tags: nginx_debug_output
- include_tasks: "{{ role_path }}/tasks/plus/delete-license.yml"
when:
- nginx_type == "plus"
- nginx_delete_license
tags: nginx_delete_license
- name: "(Config: All OSs) Ensure NGINX is Running"
meta: flush_handlers
- include_tasks: "{{ role_path }}/tasks/conf/debug-output.yml"
when: nginx_debug_output | bool
tags: nginx_debug_output
- include_tasks: "{{ role_path }}/tasks/conf/logrotate.yml"
when: nginx_logrotate_conf_enable | bool
tags: nginx_logrotate_config
when: nginx_enable | bool
- include_tasks: "{{ role_path }}/tasks/amplify/install-amplify.yml"
@ -75,7 +82,3 @@
- include_tasks: "{{ role_path }}/tasks/unit/install-unit.yml"
when: nginx_unit_enable | bool
tags: nginx_install_unit
- include_tasks: "{{ role_path }}/tasks/conf/logrotate.yml"
when: nginx_logrotate_conf_enable | bool
tags: nginx_logrotate_config