forked from evolix/ansible-roles
Fix logrotate error for varnish*
This commit is contained in:
parent
cda0932aad
commit
0156555920
|
@ -28,3 +28,12 @@
|
||||||
src: varnish.conf
|
src: varnish.conf
|
||||||
dest: /etc/systemd/system/varnish.service.d/
|
dest: /etc/systemd/system/varnish.service.d/
|
||||||
notify: reload systemctl
|
notify: reload systemctl
|
||||||
|
|
||||||
|
- name: Patch logrotate conf
|
||||||
|
replace:
|
||||||
|
name: /etc/logrotate.d/varnish
|
||||||
|
regexp: "/usr/sbin/invoke-rc.d {{item}} reload.*$"
|
||||||
|
replace: "systemctl -q is-active {{item}} && /usr/sbin/invoke-rc.d {{item}} reload > /dev/null ||true"
|
||||||
|
with_items:
|
||||||
|
- varnishlog
|
||||||
|
- varnishncsa
|
||||||
|
|
Loading…
Reference in a new issue