nix-conf/system/modules/wireguard.nix
2025-03-10 16:39:41 +08:00

14 lines
198 B
Nix

{
...
}:
let
configPath = "/etc/wireguard/wg0.conf";
in
{
networking = {
firewall = {
allowedUDPPorts = [ 51820 ];
};
wg-quick.interfaces.wg0.configFile = configPath;
};
}