fix: network config for nix-darwin

This commit is contained in:
winston 2023-02-28 04:56:52 +01:00
parent b55abee6b2
commit 5dd062efce
Signed by: winston
GPG key ID: 3786770EDBC2B481

View file

@ -5,7 +5,8 @@
}: let
inherit (pkgs.stdenv.hostPlatform) isLinux;
in {
services = {
services =
{
dnsmasq =
if isLinux
then {
@ -30,8 +31,14 @@ in {
addresses."test" = "127.0.0.1";
bind = "127.0.0.1";
};
stubby = lib.mkIf isLinux {
}
// (
if isLinux
then {
mullvad-vpn = {
enable = true;
};
stubby = {
enable = true;
settings = {
resolution_type = "GETDNS_RESOLUTION_STUB";
@ -50,7 +57,7 @@ in {
];
};
};
mullvad-vpn.enable = isLinux;
};
}
else {}
);
}