nixos-config/modules/system/services/server/wireguard/client/default.nix
2025-04-16 20:40:59 -04:00

14 lines
405 B
Nix

{ config, lib, ... }:
{
networking.wg-quick.interfaces.wgc = lib.mkIf config.services.wireguard.client.enable {
privateKey = config.secrets.wg.clientKey;
peers = [
{ # Main home server
publicKey = "qnOT/lXOJMaQgDUdXpyfGZB2IEyUouRje2m/bCe9ux8=";
allowedIPs = [ "11.0.0.0/8" ];
endpoint = "sv.nixfox.ca:51820";
persistentKeepalive = 25;
}
];
};
}