auto wg_{{ item.name }} iface w_{{ item.name }} inet static {% for i in item.ip %} address {{ i }} {% endif %} pre-up ip link add $IFACE type wireguard pre-up wg setconf $IFACE /etc/wireguard/$IFACE.conf post-down ip link del $IFACE iface w_{{ item.name }} inet6 static # static IP address {% for i in item.ip6 %} address {{ i }} {% endif %}