fix: network config for nix-darwin
This commit is contained in:
parent
b55abee6b2
commit
5dd062efce
1 changed files with 52 additions and 45 deletions
|
@ -5,7 +5,8 @@
|
||||||
}: let
|
}: let
|
||||||
inherit (pkgs.stdenv.hostPlatform) isLinux;
|
inherit (pkgs.stdenv.hostPlatform) isLinux;
|
||||||
in {
|
in {
|
||||||
services = {
|
services =
|
||||||
|
{
|
||||||
dnsmasq =
|
dnsmasq =
|
||||||
if isLinux
|
if isLinux
|
||||||
then {
|
then {
|
||||||
|
@ -30,8 +31,14 @@ in {
|
||||||
addresses."test" = "127.0.0.1";
|
addresses."test" = "127.0.0.1";
|
||||||
bind = "127.0.0.1";
|
bind = "127.0.0.1";
|
||||||
};
|
};
|
||||||
|
}
|
||||||
stubby = lib.mkIf isLinux {
|
// (
|
||||||
|
if isLinux
|
||||||
|
then {
|
||||||
|
mullvad-vpn = {
|
||||||
|
enable = true;
|
||||||
|
};
|
||||||
|
stubby = {
|
||||||
enable = true;
|
enable = true;
|
||||||
settings = {
|
settings = {
|
||||||
resolution_type = "GETDNS_RESOLUTION_STUB";
|
resolution_type = "GETDNS_RESOLUTION_STUB";
|
||||||
|
@ -50,7 +57,7 @@ in {
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
}
|
||||||
mullvad-vpn.enable = isLinux;
|
else {}
|
||||||
};
|
);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue