ansible/roles/mesh_wg/tasks/main.yml

32 lines
791 B
YAML
Raw Normal View History

---
- name: Enable backports
apt_repository: repo='deb http://deb.debian.org/debian buster-backports main'
- name: Install kernel headers
apt: name=linux-headers-amd64
- name: Install wireguard from backports
apt:
name:
- wireguard-dkms
- wireguard-tools
default_release: buster-backports
- name: Create wireguard config directory
file:
path: /etc/wireguard
state: directory
mode: 0700
- name: Configure wireguard options
template: src=wg.conf.j2 dest=/etc/wireguard/wg-{{ site_code }}.conf mode=0600
notify: Reload interfaces
- name: Configure mesh interfaces
template: src=mesh_wg.conf.j2 dest=/etc/network/interfaces.d/mesh_wg.conf
notify: Reload interfaces
- name: Install wgskex
apt: deb=http://moepman.eu/tmp/wgskex_0.1.0_amd64.deb