mirror of
https://github.com/foo-dogsquared/nixos-config.git
synced 2025-02-07 12:19:07 +00:00
hosts/ni: update personal VPN config
This commit is contained in:
parent
23e00d0472
commit
57d897ac82
@ -223,6 +223,12 @@ in
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
services.resolved.domains = [
|
||||||
|
"~plover.foodogsquared.one"
|
||||||
|
"~0.27.172.in-addr.arpa"
|
||||||
|
"~0.28.172.in-addr.arpa"
|
||||||
|
];
|
||||||
|
|
||||||
system.stateVersion = "23.05"; # Yes! I read the comment!
|
system.stateVersion = "23.05"; # Yes! I read the comment!
|
||||||
|
|
||||||
# Setting up Wireguard as a VPN tunnel. Since this is a laptop that meant to
|
# Setting up Wireguard as a VPN tunnel. Since this is a laptop that meant to
|
||||||
@ -236,18 +242,20 @@ in
|
|||||||
domains = [
|
domains = [
|
||||||
"~plover.foodogsquared.one"
|
"~plover.foodogsquared.one"
|
||||||
"~0.27.172.in-addr.arpa"
|
"~0.27.172.in-addr.arpa"
|
||||||
|
"~0.28.172.in-addr.arpa"
|
||||||
];
|
];
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
privateKeyFile = config.sops.secrets."ni/wireguard/private-key".path;
|
privateKeyFile = config.sops.secrets."ni/wireguard/private-key".path;
|
||||||
listenPort = wireguardPort;
|
listenPort = wireguardPort;
|
||||||
dns = with wireguardPeers.server; [ IPv4 IPv6 ];
|
dns = with interfaces.internal; [ IPv4.address IPv6.address ];
|
||||||
postUp =
|
postUp =
|
||||||
let
|
let
|
||||||
resolvectl = "${lib.getBin pkgs.systemd}/bin/resolvectl";
|
resolvectl = "${lib.getBin pkgs.systemd}/bin/resolvectl";
|
||||||
in
|
in
|
||||||
''
|
''
|
||||||
${resolvectl} domain %i ${lib.concatStringsSep " " domains}
|
${resolvectl} domain ${wireguardIFName} ${lib.concatStringsSep " " domains}
|
||||||
|
${resolvectl} dnssec ${wireguardIFName} no
|
||||||
'';
|
'';
|
||||||
|
|
||||||
address = with wireguardPeers.desktop; [
|
address = with wireguardPeers.desktop; [
|
||||||
|
Loading…
Reference in New Issue
Block a user