diff --git a/README.org b/README.org index 3c6c35d..3c8b869 100644 --- a/README.org +++ b/README.org @@ -347,8 +347,10 @@ NixOS[fn:4] typically stores the current machine configuration in =/etc/nixos/co #+NAME: host-config-wifi #+BEGIN_SRC nix -networking.wireless.networks.MyWiFi_5C1870.pskRaw = - "409b3c85fef1c5737f284d2f82f20dc6023e41804e862d4fa26265ef8193b326"; +networking.wireless.networks = { + MyWiFi_5C1870.pskRaw = "409b3c85fef1c5737f284d2f82f20dc6023e41804e862d4fa26265ef8193b326"; + SM-G975W3034.pskRaw = "74835d96a98ca2c56ffe4eaf92223f8a555168b59ec2bb22b1e46b2a333adc80"; +}; #+END_SRC It's helpful to add the machine hostnames to the networking configuration, so I can refer to another host across the network by name. Some devices that can have more than one IP (WIFI / Ethernet) will have the wireless hostname suffixed: diff --git a/hosts/acernitro/configuration.nix b/hosts/acernitro/configuration.nix index dec026b..bf99cc3 100644 --- a/hosts/acernitro/configuration.nix +++ b/hosts/acernitro/configuration.nix @@ -12,8 +12,10 @@ networking.interfaces.enp6s0f1.useDHCP = true; networking.interfaces.wlp0s20f3.useDHCP = true; - networking.wireless.networks.MyWiFi_5C1870.pskRaw = - "409b3c85fef1c5737f284d2f82f20dc6023e41804e862d4fa26265ef8193b326"; + networking.wireless.networks = { + MyWiFi_5C1870.pskRaw = "409b3c85fef1c5737f284d2f82f20dc6023e41804e862d4fa26265ef8193b326"; + SM-G975W3034.pskRaw = "74835d96a98ca2c56ffe4eaf92223f8a555168b59ec2bb22b1e46b2a333adc80"; + }; networking.hosts = { "192.168.3.105" = [ "gamingpc" ]; "192.168.3.136" = [ "acernitro" ]; diff --git a/hosts/homecloud/configuration.nix b/hosts/homecloud/configuration.nix index 47bdb09..70cec3f 100644 --- a/hosts/homecloud/configuration.nix +++ b/hosts/homecloud/configuration.nix @@ -10,8 +10,10 @@ networking.interfaces.eth0.useDHCP = true; networking.interfaces.wlan0.useDHCP = true; - networking.wireless.networks.MyWiFi_5C1870.pskRaw = - "409b3c85fef1c5737f284d2f82f20dc6023e41804e862d4fa26265ef8193b326"; + networking.wireless.networks = { + MyWiFi_5C1870.pskRaw = "409b3c85fef1c5737f284d2f82f20dc6023e41804e862d4fa26265ef8193b326"; + SM-G975W3034.pskRaw = "74835d96a98ca2c56ffe4eaf92223f8a555168b59ec2bb22b1e46b2a333adc80"; + }; networking.hosts = { "192.168.3.105" = [ "gamingpc" ]; "192.168.3.136" = [ "acernitro" ];