xoxys.openvpn_client/handlers/main.yml

10 lines
279 B
YAML
Raw Normal View History

2020-05-15 09:21:59 +00:00
---
- name: Restart openvpn client
service:
name: "{{ __openvpn_service_prefix }}@{{ openvpn_client_name }}"
2020-05-15 13:24:17 +00:00
state: "{{ 'restarted' if openvpn_service_state == 'started' else 'stopped' }}"
2020-05-15 09:21:59 +00:00
enabled: yes
listen: __openvpn_restart
become: True
become_user: root