aboutsummaryrefslogtreecommitdiff
path: root/modules/networking/nixos/networkd.nix
diff options
context:
space:
mode:
Diffstat (limited to 'modules/networking/nixos/networkd.nix')
-rw-r--r--modules/networking/nixos/networkd.nix44
1 files changed, 0 insertions, 44 deletions
diff --git a/modules/networking/nixos/networkd.nix b/modules/networking/nixos/networkd.nix
deleted file mode 100644
index 2c7f580..0000000
--- a/modules/networking/nixos/networkd.nix
+++ /dev/null
@@ -1,44 +0,0 @@
-{
- # lib,
- config,
- ...
-}: let
- cfg = config.collinux.system.network;
- dhcp_enabled = cfg.static == null;
-
- device =
- if (cfg.wireless == null)
- then "eth0"
- else "wl*";
-in {
- networking.useNetworkd = true;
- systemd.network = {
- enable = true;
-
- wait-online = {
- enable = true;
- ignoredInterfaces = ["docker0"];
- anyInterface = true;
- };
-
- networks."11-default" =
- if dhcp_enabled
- then {
- name = device;
- networkConfig.DHCP = "yes";
-
- # never accept dhcp dns
- dhcpV4Config.UseDNS = "no";
- dhcpV6Config.UseDNS = "no";
- }
- else {
- name = device;
- networkConfig = {
- Address = cfg.static.ip;
- Gateway = cfg.static.gateway;
- DHCP = "no";
- # DNS is managed by systemd-resolved (not specified here)
- };
- };
- };
-}