diff options
author | Peter Simons <simons@cryp.to> | 2011-09-14 18:20:50 +0000 |
---|---|---|
committer | Peter Simons <simons@cryp.to> | 2011-09-14 18:20:50 +0000 |
commit | eb6e1310b8774f3aed4c5675d09708f0df6199d3 (patch) | |
tree | 3297542b3cda78d38731abb65837f4553cd377a9 /modules/services/networking/dhclient.nix | |
parent | f5e8d35f8e76755febf97ca8f62b0700a8b6d20a (diff) | |
download | nixlib-eb6e1310b8774f3aed4c5675d09708f0df6199d3.tar nixlib-eb6e1310b8774f3aed4c5675d09708f0df6199d3.tar.gz nixlib-eb6e1310b8774f3aed4c5675d09708f0df6199d3.tar.bz2 nixlib-eb6e1310b8774f3aed4c5675d09708f0df6199d3.tar.lz nixlib-eb6e1310b8774f3aed4c5675d09708f0df6199d3.tar.xz nixlib-eb6e1310b8774f3aed4c5675d09708f0df6199d3.tar.zst nixlib-eb6e1310b8774f3aed4c5675d09708f0df6199d3.zip |
strip trailing whitespace; no functional change
svn path=/nixos/trunk/; revision=29285
Diffstat (limited to 'modules/services/networking/dhclient.nix')
-rw-r--r-- | modules/services/networking/dhclient.nix | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/modules/services/networking/dhclient.nix b/modules/services/networking/dhclient.nix index 2acef81e1e52..0a353ae1eab4 100644 --- a/modules/services/networking/dhclient.nix +++ b/modules/services/networking/dhclient.nix @@ -8,7 +8,7 @@ let # Don't start dhclient on explicitly configured interfaces or on # interfaces that are part of a bridge. - ignoredInterfaces = + ignoredInterfaces = map (i: i.name) (lib.filter (i: i ? ipAddress && i.ipAddress != "" ) config.networking.interfaces) ++ concatLists (attrValues (mapAttrs (n: v: v.interfaces) config.networking.bridges)); @@ -29,7 +29,7 @@ let # anything ever again ("couldn't resolve ..., giving up on # it"), so we silently lose time synchronisation. ${config.system.build.upstart}/sbin/initctl stop ntpd - + ${config.system.build.upstart}/sbin/initctl emit -n ip-up fi @@ -37,7 +37,7 @@ let ${config.system.build.upstart}/sbin/initctl emit -n ip-down fi ''; - + in { @@ -45,7 +45,7 @@ in ###### interface options = { - + networking.useDHCP = mkOption { default = true; merge = mergeEnableOption; @@ -55,15 +55,15 @@ in configured. "; }; - + }; ###### implementation - + config = mkIf config.networking.useDHCP { - jobs.dhclient = + jobs.dhclient = { startOn = "started network-interfaces"; stopOn = "stopping network-interfaces"; @@ -83,7 +83,7 @@ in # (1), i.e. Ethernet. Ignore peth* devices; on Xen, # they're renamed physical Ethernet cards used for # bridging. Likewise for vif* and tap* (Xen) and - # virbr* and vnet* (libvirt). + # virbr* and vnet* (libvirt). if [ "$(cat /sys/class/net/$i/type)" = 1 ]; then if ! for j in ${toString ignoredInterfaces}; do echo $j; done | grep -F -x -q "$i" && ! echo "$i" | grep -x -q "peth.*\|vif.*\|tap.*\|virbr.*\|vnet.*"; @@ -121,7 +121,7 @@ in initctl restart dhclient ''; - }; - + }; + } |