infrastructure/ansible/roles/glinet_vpn/tasks/main.yml
Jake Howard d5a7a61171
All checks were successful
/ terraform (push) Successful in 38s
/ ansible (push) Successful in 1m30s
Remove unnecessary use of become from some roles
This should make execution much faster
2024-09-09 17:09:03 +01:00

30 lines
598 B
YAML

- name: Include vault
include_vars: vault.yml
- name: Install wireguard tools
package:
name: "{{ item }}"
loop:
- wireguard-tools
- qrencode
- name: Wireguard server config
template:
src: files/server.conf
dest: /etc/wireguard/glinet.conf
mode: "0600"
backup: true
notify: restart wireguard
- name: Wireguard client config
template:
src: files/client.conf
dest: "{{ me.home }}/glinet-vpn.conf"
mode: "0600"
owner: "{{ me.user }}"
notify: restart wireguard
- name: Enable wireguard
service:
name: wg-quick@glinet
enabled: true