Skip to content
Snippets Groups Projects
Commit 4635ad4f authored by Christian Elberfeld's avatar Christian Elberfeld
Browse files

syntax and logfile fix

parent 3d992924
No related branches found
No related tags found
No related merge requests found
......@@ -19,18 +19,22 @@
# Konfigurationsdateien erstellen (ohne Keys)
- name: Konfigurationen (server) erstellen
template: src={{ inventory_hostname }}-{{ item }}.conf dest=/etc/openvpn/server/{{ item }}.conf
template:
src: "{{ inventory_hostname }}-{{ item }}.conf"
dest: "/etc/openvpn/server/{{ item }}.conf"
with_items:
- "{{ openvpn_server }}"
notify: restart openvpn server
when: openvpn_server is defined and openvpn_server > 0
when: openvpn_server is defined and (openvpn_server|length) > 0
- name: Konfigurationen (clients) erstellen
template: src={{ inventory_hostname }}-{{ item }}.conf dest=/etc/openvpn/client/{{ item }}.conf
template:
src: "{{ inventory_hostname }}-{{ item }}.conf"
dest: "/etc/openvpn/client/{{ item }}.conf"
with_items:
- "{{ openvpn_clients }}"
notify: restart openvpn clients
when: openvpn_clients is defined and openvpn_clients > 0
when: openvpn_clients is defined and (openvpn_clients|length) > 0
- name: OpenVpn LogRotate config erstellen
template:
......@@ -47,7 +51,7 @@
daemon_reload: yes
with_items:
- "{{ openvpn_server }}"
when: openvpn_server is defined and openvpn_server > 0
when: openvpn_server is defined and (openvpn_server|length) > 0
- name: enable openvpn systemd service (client)
systemd:
......@@ -57,4 +61,4 @@
daemon_reload: yes
with_items:
- "{{ openvpn_clients }}"
when: openvpn_clients is defined and openvpn_clients > 0
when: openvpn_clients is defined and (openvpn_clients|length) > 0
......@@ -6,6 +6,6 @@ ifconfig 10.43.1.1 10.43.1.2
route 192.168.0.0 255.255.255.0
secret /etc/openvpn/server/server-zone.key
log /var/log/openvpn/server-zone.conf
log /var/log/openvpn/server-zone.log
{% include "openvpn-common" %}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment