replace new lines

This commit is contained in:
Antonio J. Delgado 2023-04-06 20:34:26 +03:00
parent 4a1926a900
commit 0789d46ccb

View file

@ -46,7 +46,7 @@
path: "/var/lib/from_repos/wireguard_peers/{{ interface_name }}/{{ inventory_hostname }}.conf"
section: Peer
option: PublicKey
value: "{{ public_key }}"
value: "{{ public_key | replace('\n', '')}}"
create: true
backup: true
@ -73,7 +73,7 @@
args:
chdir: '/var/lib/from_repos/wireguard_peers/'
- name: Ensure Wireguard client is configure
- name: Ensure Wireguard client is configured
shell: "/var/lib/from_repos/wireguard_peers/update_configuration.sh '${vpnes_ip}' '${vpnes_port}'"
- name: Restart Wireguard service
@ -83,7 +83,7 @@
enabled: yes
daemon_reload: yes
# - name: Ensure Wireguard client is configure
# - name: Ensure Wireguard client is configured
# template:
# src: templates/wireguard_client.conf
# dest: "/etc/wireguard/{{ interface_name }}.conf"