network-manager: add support for internal DHCP
This commit is contained in:
parent
1fe17ee116
commit
a087081ebb
@ -12,6 +12,7 @@ let
|
|||||||
configFile = writeText "NetworkManager.conf" ''
|
configFile = writeText "NetworkManager.conf" ''
|
||||||
[main]
|
[main]
|
||||||
plugins=keyfile
|
plugins=keyfile
|
||||||
|
dhcp=${cfg.dhcp}
|
||||||
dns=${if cfg.useDnsmasq then "dnsmasq" else "default"}
|
dns=${if cfg.useDnsmasq then "dnsmasq" else "default"}
|
||||||
|
|
||||||
[keyfile]
|
[keyfile]
|
||||||
@ -21,7 +22,7 @@ let
|
|||||||
''unmanaged-devices=${lib.concatStringsSep ";" cfg.unmanaged}''}
|
''unmanaged-devices=${lib.concatStringsSep ";" cfg.unmanaged}''}
|
||||||
|
|
||||||
[logging]
|
[logging]
|
||||||
level=WARN
|
level=${cfg.logLevel}
|
||||||
|
|
||||||
[connection]
|
[connection]
|
||||||
ipv6.ip6-privacy=2
|
ipv6.ip6-privacy=2
|
||||||
@ -138,6 +139,22 @@ in {
|
|||||||
apply = list: (attrValues cfg.basePackages) ++ list;
|
apply = list: (attrValues cfg.basePackages) ++ list;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
dhcp = mkOption {
|
||||||
|
type = types.enum [ "dhclient" "dhcpcd" "internal" ];
|
||||||
|
default = "dhclient";
|
||||||
|
description = ''
|
||||||
|
Which program (or internal library) should be used for DHCP.
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
logLevel = mkOption {
|
||||||
|
type = types.enum [ "OFF" "ERR" "WARN" "INFO" "DEBUG" "TRACE" ];
|
||||||
|
default = "WARN";
|
||||||
|
description = ''
|
||||||
|
Set the default logging verbosity level.
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
appendNameservers = mkOption {
|
appendNameservers = mkOption {
|
||||||
type = types.listOf types.str;
|
type = types.listOf types.str;
|
||||||
default = [];
|
default = [];
|
||||||
@ -181,7 +198,7 @@ in {
|
|||||||
};
|
};
|
||||||
|
|
||||||
type = mkOption {
|
type = mkOption {
|
||||||
type = types.enum (attrNames dispatcherTypesSubdirMap);
|
type = types.enum (attrNames dispatcherTypesSubdirMap);
|
||||||
default = "basic";
|
default = "basic";
|
||||||
description = ''
|
description = ''
|
||||||
Dispatcher hook type. Only basic hooks are currently available.
|
Dispatcher hook type. Only basic hooks are currently available.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user