mirror of https://dev.ccchb.de/ccchb/ansible.git
Use path variables for Rspamd. Changes #31
This commit is contained in:
parent
e7eeb4039a
commit
53f05a7071
|
@ -5,16 +5,16 @@
|
|||
state: reloaded
|
||||
|
||||
- name: Restart Rspamd
|
||||
command: s6-svc -wR -T 5000 -ru /run/service/rspamd
|
||||
command: s6-svc -wR -T 5000 -ru {{ s6_scan_dir }}/rspamd
|
||||
|
||||
- name: Restart Rspamd log
|
||||
command: s6-svc -wR -T 5000 -ru /run/service/rspamd-log
|
||||
command: s6-svc -wR -T 5000 -ru {{ s6_scan_dir }}/rspamd-log
|
||||
|
||||
- name: Restart HAProxy
|
||||
command: s6-svc -wU -T 5000 -ru /run/service/haproxy
|
||||
command: s6-svc -wU -T 5000 -ru {{ s6_scan_dir }}/haproxy
|
||||
|
||||
- name: Restart HAProxy log
|
||||
command: s6-svc -wU -T 5000 -ru /run/service/haproxy-log
|
||||
command: s6-svc -wU -T 5000 -ru {{ s6_scan_dir }}/haproxy-log
|
||||
|
||||
- name: Reload HAProxy
|
||||
command: s6-svc -2 /run/service/haproxy
|
||||
command: s6-svc -2 {{ s6_scan_dir }}/haproxy
|
||||
|
|
|
@ -43,7 +43,7 @@
|
|||
|
||||
- name: Create Rspamd service directories
|
||||
file:
|
||||
path: '/etc/s6-rc/service/{{ item }}'
|
||||
path: '{{ s6_etc_dir }}/service/{{ item }}'
|
||||
state: directory
|
||||
owner: root
|
||||
group: wheel
|
||||
|
@ -56,7 +56,7 @@
|
|||
|
||||
- name: Generate Rspamd service scripts
|
||||
template:
|
||||
dest: '/etc/s6-rc/service/{{ item }}'
|
||||
dest: '{{ s6_etc_dir }}/service/{{ item }}'
|
||||
src: '{{ item }}.j2'
|
||||
mode: 0555
|
||||
owner: root
|
||||
|
@ -69,7 +69,7 @@
|
|||
|
||||
- name: Generate Rspamd service configuration
|
||||
copy:
|
||||
dest: '/etc/s6-rc/service/{{ item.name }}'
|
||||
dest: '{{ s6_etc_dir }}/service/{{ item.name }}'
|
||||
content: '{{ item.content }}'
|
||||
mode: 0444
|
||||
owner: root
|
||||
|
@ -86,13 +86,13 @@
|
|||
meta: flush_handlers
|
||||
|
||||
- name: Start Rspamd
|
||||
command: fdmove -c 2 1 s6-rc -u -v 2 -t 15000 change rspamd
|
||||
command: fdmove -c 2 1 s6-rc -l {{ s6_live_dir }} -u -v 2 -t 15000 change rspamd
|
||||
register: change
|
||||
changed_when: change.stdout | length > 0
|
||||
|
||||
- name: Enable Rspamd
|
||||
lineinfile:
|
||||
path: /etc/s6-rc/service/enabled/contents
|
||||
path: '{{ s6_etc_dir }}/service/enabled/contents'
|
||||
regexp: "^rspamd$"
|
||||
line: rspamd
|
||||
state: present
|
||||
|
|
Loading…
Reference in New Issue