Change the nginx restart into a handler, to make it more reusable in other roles.
This commit is contained in:
parent
ec7f841a7c
commit
9682c28b0e
|
@ -8,3 +8,6 @@
|
|||
service: name=supervisor state=restarted
|
||||
sudo: yes
|
||||
|
||||
- name: restart nginx
|
||||
service: name=nginx state=restarted
|
||||
sudo: yes
|
||||
|
|
|
@ -16,10 +16,7 @@
|
|||
- name: disable default configuration
|
||||
file: state=absent path=/etc/nginx/sites-enabled/default
|
||||
sudo: yes
|
||||
|
||||
- name: restart nginx
|
||||
service: name=nginx state=restarted
|
||||
sudo: yes
|
||||
notify: restart nginx
|
||||
|
||||
- name: set nginx directories permissions
|
||||
file: path={{ item }} state=directory
|
||||
|
|
Loading…
Reference in New Issue