diff --git a/configs/wifi-at-db.nix b/configs/wifi-at-db.nix new file mode 100644 index 0000000..adfc440 --- /dev/null +++ b/configs/wifi-at-db.nix @@ -0,0 +1,20 @@ +{ lib, ... }: +let + ssids = [ "WIFIonICE" "WIFI@DB" ]; +in +{ + # ref https://gist.github.com/sunsided/7840e89ff4e11b64a2d7503fafa0290c + virtualisation.docker.extraOptions = lib.concatStringsSep " " [ + "--bip=172.39.1.5/24" + "--fixed-cidr=172.39.1.0/25" + ]; + + networking.wireless.networks = lib.listToAttrs (map (ssid: {name = ssid; value = {};}) ssids); + + # fix dns + systemd.network.networks.wifi-at-db = { + networkConfig.DHCP = "yes"; + matchConfig.Name = "wlp3s0"; + matchConfig.SSID = lib.concatStringsSep " " ssids; + }; +} diff --git a/configs/wifi.nix b/configs/wifi.nix index 54a204c..8c7d64f 100644 --- a/configs/wifi.nix +++ b/configs/wifi.nix @@ -1,5 +1,7 @@ { pkgs, ... }: { + imports = [ ./wifi-at-db.nix ]; + networking.wireless = { enable = true; userControlled.enable = true; @@ -24,7 +26,6 @@ "wannseeforum" = { }; # login via curl -XPOST http://WannseeLancom.intern.:80/authen/login/ -d userid=$USER_ID -d password=$PASSWORD "Hotel_Krone" = { }; # login: http://192.168.10.1/ "Ni/Schukajlow".pskRaw = "ffc47f6829da59c48aea878a32252223303f5c47a3859edc90971ffc63346781"; - "WIFIonICE" = { }; # login: http://10.101.64.10/ "WLAN-914742".psk = "67647139648174545446"; "KDG-CEAA4".psk = "PBkBSmejcvM4"; "KDG-4ECF7".psk = "Gdbwh7afw2Bx";