copr: use systemd drop-ins instead of chaning /usr
This commit is contained in:
parent
259b3878c1
commit
612af5e20c
4 changed files with 9 additions and 21 deletions
|
@ -0,0 +1,3 @@
|
||||||
|
# Keep httpd master running when child is OOM killed, rhbz#1947475
|
||||||
|
[Service]
|
||||||
|
OOMPolicy = continue
|
|
@ -0,0 +1,4 @@
|
||||||
|
# When httpd is OOM killed or otherwise failed, start it again
|
||||||
|
[Service]
|
||||||
|
Restart = on-failure
|
||||||
|
RestartSec = 5s
|
|
@ -82,27 +82,6 @@
|
||||||
regexp: '^LoadModule substitute_module modules/mod_substitute.so'
|
regexp: '^LoadModule substitute_module modules/mod_substitute.so'
|
||||||
line: '#LoadModule substitute_module modules/mod_substitute.so'
|
line: '#LoadModule substitute_module modules/mod_substitute.so'
|
||||||
|
|
||||||
- name: Keep httpd master running when child is OOM killed, rhbz#1947475
|
|
||||||
ini_file:
|
|
||||||
path: /usr/lib/systemd/system/httpd.service
|
|
||||||
section: Service
|
|
||||||
option: OOMPolicy
|
|
||||||
value: continue
|
|
||||||
backup: yes
|
|
||||||
notify: restart apache
|
|
||||||
|
|
||||||
- name: When httpd is OOM killed or otherwise failed, start it again
|
|
||||||
ini_file:
|
|
||||||
path: /usr/lib/systemd/system/httpd.service
|
|
||||||
section: Service
|
|
||||||
option: "{{ item.option }}"
|
|
||||||
value: "{{ item.value }}"
|
|
||||||
backup: yes
|
|
||||||
with_items:
|
|
||||||
- { option: "Restart", value: "on-failure" }
|
|
||||||
- { option: "RestartSec", value: "5s" }
|
|
||||||
notify: restart apache
|
|
||||||
|
|
||||||
- include_role:
|
- include_role:
|
||||||
name: keytab/service
|
name: keytab/service
|
||||||
vars:
|
vars:
|
||||||
|
|
|
@ -141,6 +141,8 @@
|
||||||
|
|
||||||
- name: install custom systemd service files
|
- name: install custom systemd service files
|
||||||
copy: src=systemd dest=/etc
|
copy: src=systemd dest=/etc
|
||||||
|
notify:
|
||||||
|
- reload httpd
|
||||||
|
|
||||||
- name: compress rotated httpd logs
|
- name: compress rotated httpd logs
|
||||||
copy: src="httpd.logrotate" dest="/etc/logrotate.d/httpd"
|
copy: src="httpd.logrotate" dest="/etc/logrotate.d/httpd"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue