forked from ccchb/ansible
Enable HAProxy service
This commit is contained in:
parent
02fdf86327
commit
3609982b4c
1 changed files with 16 additions and 0 deletions
|
@ -180,3 +180,19 @@
|
|||
|
||||
- name: Flush handlers
|
||||
meta: flush_handlers
|
||||
|
||||
- name: Start HAProxy
|
||||
command: fdmove -c 2 1 s6-rc -u -v 2 change haproxy
|
||||
register: change
|
||||
changed_when: change.stdout | length > 0
|
||||
|
||||
- name: Enable HAProxy
|
||||
lineinfile:
|
||||
path: /etc/s6-rc/service/enabled/contents
|
||||
regexp: "^haproxy$"
|
||||
line: "haproxy"
|
||||
notify:
|
||||
- Reload s6-rc
|
||||
|
||||
- name: Flush handlers (again)
|
||||
meta: flush_handlers
|
||||
|
|
Loading…
Reference in a new issue