From 63c0fa7a1f585a7b468ef0d2559ec870f24e4004 Mon Sep 17 00:00:00 2001 From: genofire Date: Thu, 2 Dec 2021 23:30:42 +0100 Subject: [PATCH] nixos: fix network only on sway with systemd-networkd --- nixos/desktop-sway.nix | 31 +++++++++++++++++++++++++++++++ nixos/desktop.nix | 31 ------------------------------- 2 files changed, 31 insertions(+), 31 deletions(-) diff --git a/nixos/desktop-sway.nix b/nixos/desktop-sway.nix index 8a17c18..8a42028 100644 --- a/nixos/desktop-sway.nix +++ b/nixos/desktop-sway.nix @@ -2,6 +2,37 @@ { imports = [./desktop.nix]; + systemd.network.networks.wifi = { + matchConfig = { + Name = "wlan0"; + SSID = "!HotoHo-v6"; + }; + DHCP = "ipv4"; + networkConfig = { + IPv6AcceptRA = true; + IPv6PrivacyExtensions = true; + }; + }; + systemd.network.networks.wifi-v6 = { + matchConfig = { + Name = "wlan0"; + SSID = "HotoHo-v6"; + }; + networkConfig = { + DNSSEC = false; + IPv6AcceptRA = true; + IPv6PrivacyExtensions = true; + }; + }; + systemd.network.networks.eth = { + matchConfig.Name = "enp*"; + DHCP = "ipv4"; + networkConfig = { + IPv6AcceptRA = true; + IPv6PrivacyExtensions = true; + }; + }; + programs.sway = { enable = true; wrapperFeatures = { gtk = true; }; diff --git a/nixos/desktop.nix b/nixos/desktop.nix index 80610b3..055a418 100644 --- a/nixos/desktop.nix +++ b/nixos/desktop.nix @@ -18,37 +18,6 @@ }; }; - systemd.network.networks.wifi = { - matchConfig = { - Name = "wlan0"; - SSID = "!HotoHo-v6"; - }; - DHCP = "ipv4"; - networkConfig = { - IPv6AcceptRA = true; - IPv6PrivacyExtensions = true; - }; - }; - systemd.network.networks.wifi-v6 = { - matchConfig = { - Name = "wlan0"; - SSID = "HotoHo-v6"; - }; - networkConfig = { - DNSSEC = false; - IPv6AcceptRA = true; - IPv6PrivacyExtensions = true; - }; - }; - systemd.network.networks.eth = { - matchConfig.Name = "enp*"; - DHCP = "ipv4"; - networkConfig = { - IPv6AcceptRA = true; - IPv6PrivacyExtensions = true; - }; - }; - hardware.bluetooth.enable = true; sound.enable = true; hardware.pulseaudio.enable = false; #use pipewire