modules/services/networking/dhcpcd.nix: add "extraConfig" option
This option allows administrators to add verbatim text to the generated config file. I use this feature, for instance, to disable the default route normally added by dhcpcd for certain interfaces.
This commit is contained in:
parent
c52fd85990
commit
6341a12587
@ -35,6 +35,8 @@ let
|
||||
# Ethernet cards used for bridging. Likewise for vif* and tap*
|
||||
# (Xen) and virbr* and vnet* (libvirt).
|
||||
denyinterfaces ${toString ignoredInterfaces} peth* vif* tap* tun* virbr* vnet* vboxnet*
|
||||
|
||||
${config.networking.dhcpcd.extraConfig}
|
||||
'';
|
||||
|
||||
# Hook for emitting ip-up/ip-down events.
|
||||
@ -85,6 +87,13 @@ in
|
||||
'';
|
||||
};
|
||||
|
||||
networking.dhcpcd.extraConfig = mkOption {
|
||||
default = "";
|
||||
description = ''
|
||||
Literal string to append to the config file generated for dhcpcd.
|
||||
'';
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user