automatic service restarting
This commit is contained in:
parent
24ed406026
commit
64635320a5
|
@ -1,5 +1,7 @@
|
||||||
isc-dhcp-server:
|
isc-dhcp-server:
|
||||||
pkg.installed: []
|
pkg.installed: []
|
||||||
|
service:
|
||||||
|
- running
|
||||||
|
|
||||||
/etc/dhcp/dhcpd.conf:
|
/etc/dhcp/dhcpd.conf:
|
||||||
file.managed:
|
file.managed:
|
||||||
|
@ -20,8 +22,10 @@ autostart-dhcpd:
|
||||||
|
|
||||||
start-dhcpd:
|
start-dhcpd:
|
||||||
service.running:
|
service.running:
|
||||||
- name: isc-dhcp-server
|
- name: isc-dhcp-server
|
||||||
require_in:
|
require_in:
|
||||||
- file: /etc/dhcp/dhcpd.conf
|
- file: /etc/dhcp/dhcpd.conf
|
||||||
- file: /etc/default/isc-dhcp-server
|
- file: /etc/default/isc-dhcp-server
|
||||||
|
watch:
|
||||||
|
- pkg: isc-dhcp-server
|
||||||
|
- file: /etc/dhcp/dhcpd.conf
|
||||||
|
|
|
@ -24,6 +24,8 @@ start-{{ daemon }}:
|
||||||
- name: {{ daemon }}
|
- name: {{ daemon }}
|
||||||
require:
|
require:
|
||||||
- service: autostart-{{ daemon }}
|
- service: autostart-{{ daemon }}
|
||||||
|
watch:
|
||||||
|
- file: /etc/quagga/{{ daemon }}.conf
|
||||||
|
|
||||||
{%- endfor %}
|
{%- endfor %}
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,10 @@
|
||||||
unbound:
|
unbound:
|
||||||
pkg.installed: []
|
pkg.installed: []
|
||||||
|
service:
|
||||||
|
- running
|
||||||
|
- watch:
|
||||||
|
- pkg: unbound
|
||||||
|
- file: /etc/unbound/unbound.conf.d/listen.conf
|
||||||
|
|
||||||
/etc/unbound/unbound.conf.d/listen.conf:
|
/etc/unbound/unbound.conf.d/listen.conf:
|
||||||
file.managed:
|
file.managed:
|
||||||
|
|
|
@ -65,8 +65,10 @@ start-{{ name }}:
|
||||||
require_in:
|
require_in:
|
||||||
- file: /etc/openvpn/{{ name }}.conf
|
- file: /etc/openvpn/{{ name }}.conf
|
||||||
- file: /etc/openvpn/{{ name }}.auth
|
- file: /etc/openvpn/{{ name }}.auth
|
||||||
|
watch:
|
||||||
|
- file: /etc/openvpn/{{ name }}.conf
|
||||||
|
- file: /etc/openvpn/{{ name }}.auth
|
||||||
require:
|
require:
|
||||||
- file: /dev/net/tun
|
- file: /dev/net/tun
|
||||||
|
|
||||||
{%- endfor %}
|
{%- endfor %}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue