Move to new module system, allows for multiple computers

Change-Id: I9a76346b05dfff6157813c50f89d1254130fc26c
diff --git a/flake.lock b/flake.lock
index 52957ad..41320e5 100755
--- a/flake.lock
+++ b/flake.lock
@@ -37,6 +37,26 @@
         "type": "github"
       }
     },
+    "deploy-rs": {
+      "inputs": {
+        "flake-compat": "flake-compat",
+        "nixpkgs": "nixpkgs",
+        "utils": "utils"
+      },
+      "locked": {
+        "lastModified": 1704875591,
+        "narHash": "sha256-eWRLbqRcrILgztU/m/k7CYLzETKNbv0OsT2GjkaNm8A=",
+        "owner": "serokell",
+        "repo": "deploy-rs",
+        "rev": "1776009f1f3fb2b5d236b84d9815f2edee463a9b",
+        "type": "github"
+      },
+      "original": {
+        "owner": "serokell",
+        "repo": "deploy-rs",
+        "type": "github"
+      }
+    },
     "flake-compat": {
       "flake": false,
       "locked": {
@@ -56,11 +76,11 @@
     "flake-compat_2": {
       "flake": false,
       "locked": {
-        "lastModified": 1673956053,
-        "narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=",
+        "lastModified": 1696426674,
+        "narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
         "owner": "edolstra",
         "repo": "flake-compat",
-        "rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9",
+        "rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
         "type": "github"
       },
       "original": {
@@ -92,7 +112,7 @@
     },
     "flake-utils": {
       "inputs": {
-        "systems": "systems"
+        "systems": "systems_2"
       },
       "locked": {
         "lastModified": 1694529238,
@@ -108,24 +128,6 @@
         "type": "github"
       }
     },
-    "flake-utils_2": {
-      "inputs": {
-        "systems": "systems_2"
-      },
-      "locked": {
-        "lastModified": 1681202837,
-        "narHash": "sha256-H+Rh19JDwRtpVPAWp64F+rlEtxUWBAQW28eAi3SRSzg=",
-        "owner": "numtide",
-        "repo": "flake-utils",
-        "rev": "cfacdce06f30d2b68473a46042957675eebb3401",
-        "type": "github"
-      },
-      "original": {
-        "owner": "numtide",
-        "repo": "flake-utils",
-        "type": "github"
-      }
-    },
     "gitignore": {
       "inputs": {
         "nixpkgs": [
@@ -171,10 +173,12 @@
     "lanzaboote": {
       "inputs": {
         "crane": "crane",
-        "flake-compat": "flake-compat",
+        "flake-compat": "flake-compat_2",
         "flake-parts": "flake-parts",
         "flake-utils": "flake-utils",
-        "nixpkgs": "nixpkgs",
+        "nixpkgs": [
+          "nixpkgs"
+        ],
         "pre-commit-hooks-nix": "pre-commit-hooks-nix",
         "rust-overlay": "rust-overlay"
       },
@@ -194,9 +198,17 @@
     },
     "nix-vscode-extensions": {
       "inputs": {
-        "flake-compat": "flake-compat_2",
-        "flake-utils": "flake-utils_2",
-        "nixpkgs": "nixpkgs_2"
+        "flake-compat": [
+          "lanzaboote",
+          "flake-compat"
+        ],
+        "flake-utils": [
+          "lanzaboote",
+          "flake-utils"
+        ],
+        "nixpkgs": [
+          "nixpkgs"
+        ]
       },
       "locked": {
         "lastModified": 1698196718,
@@ -214,16 +226,16 @@
     },
     "nixpkgs": {
       "locked": {
-        "lastModified": 1697935353,
-        "narHash": "sha256-dDwl5ziD24Gs0feke2seFXoQibHafb5XeNDWlUZxCbg=",
+        "lastModified": 1702272962,
+        "narHash": "sha256-D+zHwkwPc6oYQ4G3A1HuadopqRwUY/JkMwHz1YF7j4Q=",
         "owner": "NixOS",
         "repo": "nixpkgs",
-        "rev": "8dfad603247387df1df4826b8bea58efc5d012d8",
+        "rev": "e97b3e4186bcadf0ef1b6be22b8558eab1cdeb5d",
         "type": "github"
       },
       "original": {
         "owner": "NixOS",
-        "ref": "nixos-unstable-small",
+        "ref": "nixpkgs-unstable",
         "repo": "nixpkgs",
         "type": "github"
       }
@@ -246,22 +258,6 @@
     },
     "nixpkgs_2": {
       "locked": {
-        "lastModified": 1684570954,
-        "narHash": "sha256-FX5y4Sm87RWwfu9PI71XFvuRpZLowh00FQpIJ1WfXqE=",
-        "owner": "NixOS",
-        "repo": "nixpkgs",
-        "rev": "3005f20ce0aaa58169cdee57c8aa12e5f1b6e1b3",
-        "type": "github"
-      },
-      "original": {
-        "owner": "NixOS",
-        "ref": "nixos-unstable",
-        "repo": "nixpkgs",
-        "type": "github"
-      }
-    },
-    "nixpkgs_3": {
-      "locked": {
         "lastModified": 1701389149,
         "narHash": "sha256-rU1suTIEd5DGCaAXKW6yHoCfR1mnYjOXQFOaH7M23js=",
         "owner": "nixos",
@@ -310,10 +306,11 @@
     "root": {
       "inputs": {
         "alacritty-themes": "alacritty-themes",
+        "deploy-rs": "deploy-rs",
         "home-manager": "home-manager",
         "lanzaboote": "lanzaboote",
         "nix-vscode-extensions": "nix-vscode-extensions",
-        "nixpkgs": "nixpkgs_3"
+        "nixpkgs": "nixpkgs_2"
       }
     },
     "rust-overlay": {
@@ -370,6 +367,24 @@
         "repo": "default",
         "type": "github"
       }
+    },
+    "utils": {
+      "inputs": {
+        "systems": "systems"
+      },
+      "locked": {
+        "lastModified": 1701680307,
+        "narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=",
+        "owner": "numtide",
+        "repo": "flake-utils",
+        "rev": "4022d587cbbfd70fe950c1e2083a02621806a725",
+        "type": "github"
+      },
+      "original": {
+        "owner": "numtide",
+        "repo": "flake-utils",
+        "type": "github"
+      }
     }
   },
   "root": "root",
diff --git a/flake.nix b/flake.nix
index da68f66..99c098e 100755
--- a/flake.nix
+++ b/flake.nix
@@ -3,7 +3,11 @@
 
   inputs = {
     nixpkgs.url = "github:nixos/nixpkgs/nixos-23.11";
+
     nix-vscode-extensions.url = "github:nix-community/nix-vscode-extensions";
+    nix-vscode-extensions.inputs.nixpkgs.follows = "nixpkgs";
+    nix-vscode-extensions.inputs.flake-compat.follows = "lanzaboote/flake-compat";
+    nix-vscode-extensions.inputs.flake-utils.follows = "lanzaboote/flake-utils";
 
     alacritty-themes.url = "github:rajasegar/alacritty-themes";
     alacritty-themes.flake = false;
@@ -11,30 +15,48 @@
     home-manager.url = "github:nix-community/home-manager";
     home-manager.inputs.nixpkgs.follows = "nixpkgs";
 
+    deploy-rs.url = "github:serokell/deploy-rs";
+
     lanzaboote.url = "github:nix-community/lanzaboote";
+    lanzaboote.inputs.nixpkgs.follows = "nixpkgs";
   };
 
-  outputs = { self, nixpkgs, home-manager, ... }@inputs: {
-    nixosConfigurations."codedPC" = nixpkgs.lib.nixosSystem {
+  outputs = { self, nixpkgs, home-manager, deploy-rs, ... }@inputs: let
+    stateVersion = "23.11";  # Only change this number on a full config rewrite.
+    modulesFor = x: (nixpkgs.lib.pipe ./modules/${x} [
+        (import ./utils/nixFilesIn.nix nixpkgs.lib)
+        (map import)
+      ]);
+  in {
+    nixosConfigurations.codedPC = nixpkgs.lib.nixosSystem {
       system = "x86_64-linux";
       modules = [
         home-manager.nixosModules.home-manager
         inputs.lanzaboote.nixosModules.lanzaboote
         {
           nix.settings.experimental-features = [ "nix-command" "flakes" ];
-          system.stateVersion = "23.11";
-          nixpkgs.config.permittedInsecurePackages = [
-            "mailspring-1.12.0"
-          ];
+          system = { inherit stateVersion; };
         }
-      ] ++ (nixpkgs.lib.pipe ./modules [
-        (import ./utils/nixFilesIn.nix nixpkgs.lib)
-        (map import)
-      ]) ++ (nixpkgs.lib.pipe ./homes [
-        (import ./utils/nixFilesIn.nix nixpkgs.lib)
-        (map import)
-      ]);
-      specialArgs = { inherit inputs; };
+      ] ++ modulesFor "common" ++ modulesFor "codedPC";
+      specialArgs = { inherit inputs; flakeRoot = ./.; };
+    };
+
+    nixosConfigurations.codedPI = nixpkgs.lib.nixosSystem {
+      system = "amd64-linux";
+      modules = [
+        home-manager.nixosModules.home-manager
+        inputs.lanzaboote.nixosModules.lanzaboote
+        {
+          nix.settings.experimental-features = [ "nix-command" "flakes" ];
+          system = { inherit stateVersion; };
+        }
+      ] ++ modulesFor "common" ++ modulesFor "codedPI";
+      specialArgs = { inherit inputs; flakeRoot = ./.; };
+    };
+
+    deploy.nodes.codedPI.profiles.system = {
+        user = "coded";
+        path = deploy-rs.lib.x86_64-linux.activate.nixos self.nixosConfigurations.codedPI;
     };
   };
 }
diff --git a/homes/coded.nix b/homes/coded.nix
deleted file mode 100644
index e2c8392..0000000
--- a/homes/coded.nix
+++ /dev/null
@@ -1,7 +0,0 @@
-{ config, ... }: {
-  users.users.coded = {
-    isNormalUser = true;
-    description = "Samuel Shuert";
-    extraGroups = [ "networkmanager" "wheel" ];
-  };
-}
diff --git a/modules/browser.nix b/modules/browser.nix
deleted file mode 100644
index d3fa947..0000000
--- a/modules/browser.nix
+++ /dev/null
@@ -1,25 +0,0 @@
-{ pkgs, ... }: {
-  home-manager.users.coded.programs.chromium = {
-    enable = true;
-    extensions = [
-      { id = "nngceckbapebfimnlniiiahkandclblb"; } # bitwarden
-      {
-        id = "dkoaabhijcomjinndlgbmfnmnjnmdeeb";
-        crxPath =
-          ../extensions/chromium/adnauseam/adnauseam-3.18.0.chromium.crx;
-        version = "3.18.0";
-      }
-      { id = "kekjfbackdeiabghhcdklcdoekaanoel"; } #MAL Sync
-      { id = "mnjggcdmjocbbbhaepdhchncahnbgone"; } #Sponsor Block
-      { id = "gebbhagfogifgggkldgodflihgfeippi"; } #return youtube dislike
-      { id = "gmkiokemhjjdjmpnnjmnpkpfoenpnpne"; } #Lofi Girl
-      { id = "fmkadmapgofadopljbjfkapdkoienihi"; } #React Dev Tools
-    ];
-  };
-  home-manager.users.coded.programs.firefox = {
-    enable = true;
-  };
-  # home-manager.users.coded.home.packages = [
-  #  pkgs.floorp
-  #];
-}
diff --git a/modules/c.nix b/modules/c.nix
deleted file mode 100644
index f0279c8..0000000
--- a/modules/c.nix
+++ /dev/null
@@ -1,8 +0,0 @@
-{ pkgs, ... }: {
-  environment.systemPackages = with pkgs; [
-    libgccjit
-    binutils
-    gcc
-    go
-  ];
-}
diff --git a/modules/audio.nix b/modules/codedPC/audio.nix
similarity index 100%
rename from modules/audio.nix
rename to modules/codedPC/audio.nix
diff --git a/modules/bluetooth.nix b/modules/codedPC/bluetooth.nix
similarity index 100%
rename from modules/bluetooth.nix
rename to modules/codedPC/bluetooth.nix
diff --git a/modules/codedPC/boot.nix b/modules/codedPC/boot.nix
new file mode 100644
index 0000000..1963a31
--- /dev/null
+++ b/modules/codedPC/boot.nix
@@ -0,0 +1,8 @@
+{
+  boot.initrd = {
+    luks.devices."luks-bf23eee1-7cb7-43b9-822f-a9f49ea0a768".device =
+      "/dev/disk/by-uuid/bf23eee1-7cb7-43b9-822f-a9f49ea0a768";
+
+    kernelModules = [ "amdgpu" ];
+  };
+}
diff --git a/modules/codedPC/browser.nix b/modules/codedPC/browser.nix
new file mode 100644
index 0000000..f253a94
--- /dev/null
+++ b/modules/codedPC/browser.nix
@@ -0,0 +1,21 @@
+{ pkgs, flakeRoot, ... }: {
+  home-manager.users.coded.programs.chromium = {
+    enable = true;
+    extensions = [ #Chrome Web Store
+      { id = "nngceckbapebfimnlniiiahkandclblb"; } #Bitwarden
+      { id = "kekjfbackdeiabghhcdklcdoekaanoel"; } #MAL Sync
+      { id = "mnjggcdmjocbbbhaepdhchncahnbgone"; } #Sponsor Block
+      { id = "gebbhagfogifgggkldgodflihgfeippi"; } #Return youtube dislike
+      { id = "gmkiokemhjjdjmpnnjmnpkpfoenpnpne"; } #Lofi Girl
+      { id = "fmkadmapgofadopljbjfkapdkoienihi"; } #React Dev Tools
+      { id = "bmnlcjabgnpnenekpadlanbbkooimhnj"; } #PayPal Honey
+    ] ++ [ #Custom
+      {
+        id = "dkoaabhijcomjinndlgbmfnmnjnmdeeb";
+        crxPath =
+          "${flakeRoot}/extensions/chromium/adnauseam/adnauseam-3.18.0.chromium.crx";
+        version = "3.18.0";
+      }
+    ];
+  };
+}
diff --git a/modules/cad.nix b/modules/codedPC/cad.nix
similarity index 100%
rename from modules/cad.nix
rename to modules/codedPC/cad.nix
diff --git a/modules/calibre.nix b/modules/codedPC/calibre.nix
similarity index 100%
rename from modules/calibre.nix
rename to modules/codedPC/calibre.nix
diff --git a/modules/games.nix b/modules/codedPC/games.nix
similarity index 100%
rename from modules/games.nix
rename to modules/codedPC/games.nix
diff --git a/modules/hardware-configuration.nix b/modules/codedPC/hardware-configuration.nix
similarity index 100%
rename from modules/hardware-configuration.nix
rename to modules/codedPC/hardware-configuration.nix
diff --git a/modules/kde_plasma.nix b/modules/codedPC/kde_plasma.nix
similarity index 100%
rename from modules/kde_plasma.nix
rename to modules/codedPC/kde_plasma.nix
diff --git a/modules/neovim.nix b/modules/codedPC/neovim.nix
similarity index 100%
rename from modules/neovim.nix
rename to modules/codedPC/neovim.nix
diff --git a/modules/codedPC/networking.nix b/modules/codedPC/networking.nix
new file mode 100644
index 0000000..0a9c8d4
--- /dev/null
+++ b/modules/codedPC/networking.nix
@@ -0,0 +1,11 @@
+{
+  networking = {
+    hostName = "codedPC";
+    networkmanager.enable = true;
+
+    firewall = {
+      enable = true;
+      allowedTCPPorts = [ 3000 ];
+    };
+  };
+}
diff --git a/modules/codedPC/packages.nix b/modules/codedPC/packages.nix
new file mode 100644
index 0000000..90bad63
--- /dev/null
+++ b/modules/codedPC/packages.nix
@@ -0,0 +1,12 @@
+{ pkgs, ... }: {
+  hardware.enableRedistributableFirmware = true;
+  home-manager.users.coded.home.packages = with pkgs; [
+    bitwarden
+    nixfmt
+    email
+    thunderbird
+    ollama
+    rpiplay
+    kdocker
+  ];
+}
diff --git a/modules/codedPC/printing.nix b/modules/codedPC/printing.nix
new file mode 100644
index 0000000..68016f8
--- /dev/null
+++ b/modules/codedPC/printing.nix
@@ -0,0 +1,6 @@
+{ pkgs, ... }: {
+    home-manager.users.coded.home.packages = with pkgs; [
+        cura
+        printrun
+    ];
+}
diff --git a/modules/codedPC/shell.nix b/modules/codedPC/shell.nix
new file mode 100644
index 0000000..997afe8
--- /dev/null
+++ b/modules/codedPC/shell.nix
@@ -0,0 +1,18 @@
+{ inputs, ... }: {
+  home-manager.users.coded.programs.alacritty = {
+    enable = true;
+    settings = {
+      window.dimensions = {
+        lines = 40;
+        columns = 150;
+      };
+      import = [
+        "${inputs.alacritty-themes}/themes/Catppuccin-Mocha.yml"
+      ];
+    };
+  };
+
+  home-manager.users.coded.programs.zsh.shellAliases = {
+    print3d = "sudo /run/current-system/sw/bin/pronsole.py";
+  };
+}
diff --git a/modules/social.nix b/modules/codedPC/social.nix
similarity index 100%
rename from modules/social.nix
rename to modules/codedPC/social.nix
diff --git a/modules/uxplay.nix b/modules/codedPC/uxplay.nix
similarity index 100%
rename from modules/uxplay.nix
rename to modules/codedPC/uxplay.nix
diff --git a/modules/video.nix b/modules/codedPC/video.nix
similarity index 100%
rename from modules/video.nix
rename to modules/codedPC/video.nix
diff --git a/modules/vscode.nix b/modules/codedPC/vscode.nix
similarity index 100%
rename from modules/vscode.nix
rename to modules/codedPC/vscode.nix
diff --git a/modules/xdgopen.nix b/modules/codedPC/xdgopen.nix
similarity index 100%
rename from modules/xdgopen.nix
rename to modules/codedPC/xdgopen.nix
diff --git a/modules/basicServices.nix b/modules/common/basicServices.nix
similarity index 100%
rename from modules/basicServices.nix
rename to modules/common/basicServices.nix
diff --git a/modules/boot.nix b/modules/common/boot.nix
similarity index 65%
rename from modules/boot.nix
rename to modules/common/boot.nix
index 1948e91..605b789 100644
--- a/modules/boot.nix
+++ b/modules/common/boot.nix
@@ -15,9 +15,5 @@
 
     };
     loader.efi.canTouchEfiVariables = true;
-    initrd.luks.devices."luks-bf23eee1-7cb7-43b9-822f-a9f49ea0a768".device =
-      "/dev/disk/by-uuid/bf23eee1-7cb7-43b9-822f-a9f49ea0a768";
-    
-    initrd.kernelModules = [ "amdgpu" ];
   };
 }
diff --git a/modules/direnv.nix b/modules/common/direnv.nix
similarity index 100%
rename from modules/direnv.nix
rename to modules/common/direnv.nix
diff --git a/modules/docker.nix b/modules/common/docker.nix
similarity index 100%
rename from modules/docker.nix
rename to modules/common/docker.nix
diff --git a/modules/git.nix b/modules/common/git.nix
similarity index 100%
rename from modules/git.nix
rename to modules/common/git.nix
diff --git a/modules/home-manager.nix b/modules/common/home-manager.nix
similarity index 100%
rename from modules/home-manager.nix
rename to modules/common/home-manager.nix
diff --git a/modules/locale.nix b/modules/common/locale.nix
similarity index 100%
rename from modules/locale.nix
rename to modules/common/locale.nix
diff --git a/modules/common/networking.nix b/modules/common/networking.nix
new file mode 100644
index 0000000..bc3db33
--- /dev/null
+++ b/modules/common/networking.nix
@@ -0,0 +1,9 @@
+{
+  networking.hosts = {
+    "192.168.0.1" = [ "a1" ];
+    "192.168.0.2" = [ "a1d1" ];
+    "192.168.0.4" = [ "CodedPi" ];
+    "192.168.0.5" = [ "SamuelDesktop" "codedPC" "me" ];
+    "192.168.0.6" = [ "a1d2" ];
+  };
+}
diff --git a/modules/packages.nix b/modules/common/packages.nix
similarity index 64%
rename from modules/packages.nix
rename to modules/common/packages.nix
index f8c0f0b..5b7de8a 100644
--- a/modules/packages.nix
+++ b/modules/common/packages.nix
@@ -1,18 +1,10 @@
 { pkgs, ... }: {
   hardware.enableRedistributableFirmware = true;
   nixpkgs.config.allowUnfree = true;
-  nixpkgs.config.permittedInsecurePackages = with pkgs; [
-    "mailspring-1.11.0"
-  ];
   home-manager.users.coded.home.packages = with pkgs; [
-    bitwarden
     sops
     nixfmt
     nextcloud-client
-    email
-    mailspring
-    ollama
-    rpiplay
   ];
   environment.systemPackages = with pkgs; [
     tmux
diff --git a/modules/security.nix b/modules/common/security.nix
similarity index 72%
rename from modules/security.nix
rename to modules/common/security.nix
index e14fd8c..7466737 100644
--- a/modules/security.nix
+++ b/modules/common/security.nix
@@ -1,10 +1,10 @@
-{
+{ flakeRoot, ... }: {
   security.pam.services = {
     login.u2fAuth = true;
     sudo.u2fAuth = true;
   };
 
-  security.pam.u2f.authFile = ../keys/u2f_mappings;
+  security.pam.u2f.authFile = "${flakeRoot}/keys/u2f_mappings";
 
   security.sudo.extraRules = [
     {
diff --git a/modules/shell.nix b/modules/common/shell.nix
similarity index 72%
rename from modules/shell.nix
rename to modules/common/shell.nix
index ec72963..1bf1ba6 100644
--- a/modules/shell.nix
+++ b/modules/common/shell.nix
@@ -2,7 +2,7 @@
   programs.zsh.enable = true;
   users.users.coded.shell = pkgs.zsh;
 
-  environment.systemPackages = with pkgs; [
+  home-manager.users.coded.home.packages = with pkgs; [
     bmon
     wget
     ripgrep
@@ -22,13 +22,10 @@
         rebuild = "sudo nixos-rebuild switch --flake /home/coded/nixConfig/";
         "gr!" = "git review";
         clr = "clear";
-        pnpx = "pnpm dlx";
-        print3d = "sudo /run/current-system/sw/bin/pronsole.py";
         nh = "wget -O ~/Documents/hashCheck $1 | nix hash file ~/Documents/hashCheck";
         edit = "nvim";
         neovim = "nvim";
         v = "nvim";
-        doom = "~/.config/emacs/bin/doom";
       };
 
       dirHashes = { code = "$HOME/Documents/programming"; };
@@ -47,20 +44,6 @@
       enable = true;
       settings = { format = "$all"; };
     };
-    
-    # Alacritty
-    alacritty = {
-      enable = true;
-      settings = {
-        window.dimensions = {
-          lines = 40;
-          columns = 150;
-        };
-        import = [
-          "${inputs.alacritty-themes}/themes/Catppuccin-Mocha.yml"
-        ];
-      };
-    };
 
     # Nix-index
     nix-index.enable = true;
diff --git a/modules/ssh.nix b/modules/common/ssh.nix
similarity index 100%
rename from modules/ssh.nix
rename to modules/common/ssh.nix
diff --git a/modules/users.nix b/modules/common/users.nix
similarity index 93%
rename from modules/users.nix
rename to modules/common/users.nix
index 8b5cdba..25c3870 100644
--- a/modules/users.nix
+++ b/modules/common/users.nix
@@ -1,7 +1,7 @@
-{pkgs, ...}: {
+{ pkgs, ... }: {
   users.users.minion = {
     isNormalUser = true;
-    extraGroups = [ "wheel" ];
+    extraGroups = [ "networkmanager" "wheel" ];
     openssh.authorizedKeys.keys = [
       "sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIIteIdlZv52nUDxW2SUsoJ2NZi/w9j1NZwuHanQ/o/DuAAAAHnNzaDpjb2xsYWJvcmFfeXViaWtleV9yZXNpZGVudA== collabora_yubikey_resident"
       "sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIJRzQbQjXFpHKtt8lpNKmoNx57+EJ/z3wnKOn3/LjM6cAAAAFXNzaDppeXViaWtleV9yZXNpZGVudA== iyubikey_resident"
@@ -10,7 +10,7 @@
   };
   users.users.coded = {
     isNormalUser = true;
-    extraGroups = [ "wheel" ];
+    extraGroups = [ "networkmanager" "wheel" ];
     openssh.authorizedKeys.keys = [
       "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQCZGErwcw5YUlJS9tAfIYOSqkiuDRZZRTJjMlrDaAiNwTjqUML/Lrcau/1KA6a0+sXCM8DhQ1e0qhh2Qxmh/kxZWO6XMVK2EB7ELPNojqFI16T8Bbhq2t7yVAqbPUhXLQ4xKGvWMCPWOCo/dY72P9yu7kkMV0kTW3nq25+8nvqIvvuQOlOUx1uyR7qEfO706O86wjVTIuwfZKyzMDIC909vyg0xS+SfFlD7MkBuGzevQnOAV3U6tyafg6XW4PaJuDLyGXwpKz6asY08F7gRL/7/GhlMB09nfFfT4sZggmqPdGAtxwsFuwHPjNSlktHz5nlHtpS0LjefR9mWiGIhw5Hw1z33lxP0rfmiEU9J7kFcXv9B8QAWFwWfNEZfeqB7h7DJruo+QRStGeDz4SwRG3GR+DB4iNJLt7n0ALkVFJpOpskeo8TV4+Fwok+hYs2GsvdEmh9Cj7dC/9CyRhJeam9iLIi/iVGZhXEE3tIiqEktZPjiK7JwQyr97zhGJ7Rj4oE= samue@SamuelDesktop"
       "sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIH+TJRuMpDPgh6Wp2h+E+O/WoyEAVyWo6SN8oxm2JZNVAAAABHNzaDo= samue@SamuelDesktop"
diff --git a/modules/emacs.nix b/modules/emacs.nix
deleted file mode 100644
index f2f7153..0000000
--- a/modules/emacs.nix
+++ /dev/null
@@ -1,12 +0,0 @@
-{ pkgs, ... }: {
-  
-  home-manager.users.coded.programs.emacs = {
-    enable = true;
-  };
-  home-manager.users.coded.services.emacs = {
-    enable = true;
-    client = {
-      enable = true;
-    };
-  };
-}
diff --git a/modules/java.nix b/modules/java.nix
deleted file mode 100644
index abe03e8..0000000
--- a/modules/java.nix
+++ /dev/null
@@ -1,7 +0,0 @@
-{ pkgs, ... }: {
-  environment.systemPackages = with pkgs; [
-    jdk8
-    jdk21
-    jdk
-  ];
-}
diff --git a/modules/mongo.nix b/modules/mongo.nix
deleted file mode 100644
index e42b184..0000000
--- a/modules/mongo.nix
+++ /dev/null
@@ -1,5 +0,0 @@
-{ config, pkgs, ... }: {
-  environment.systemPackages = [ pkgs.mongosh pkgs.mongodb-tools ];
-  services.mongodb.enable = false;
-  services.mongodb.package = pkgs.mongodb-6_0;
-}
diff --git a/modules/networking.nix b/modules/networking.nix
deleted file mode 100644
index 05997db..0000000
--- a/modules/networking.nix
+++ /dev/null
@@ -1,21 +0,0 @@
-{
-  networking = {
-    hostName = "codedPC";
-    networkmanager.enable = true;
-
-    hosts = {
-      "192.168.0.1" = [ "a1" ];
-      "192.168.0.2" = [ "a1d1" ];
-      "192.168.0.4" = [ "CodedPi" ];
-      "192.168.0.5" = [ "SamuelDesktop" "codedPC" "me" ];
-      "192.168.0.6" = [ "a1d2" ];
-    };
-
-    firewall = {
-      enable = true;
-      allowedTCPPorts = [ 3000 ];
-    };
-  };
-
-  
-}
diff --git a/modules/node.nix b/modules/node.nix
deleted file mode 100644
index 24c3e32..0000000
--- a/modules/node.nix
+++ /dev/null
@@ -1,8 +0,0 @@
-{ pkgs, ... }: {
-    home-manager.users.coded.home.packages = with pkgs; [
-      nodejs_20
-      bun
-      nodePackages.pnpm
-      nodePackages.typescript
-    ];
-}
diff --git a/modules/printing.nix b/modules/printing.nix
deleted file mode 100644
index 2c22100..0000000
--- a/modules/printing.nix
+++ /dev/null
@@ -1,6 +0,0 @@
-{ pkgs, ... }: {
-    environment.systemPackages = with pkgs; [
-        cura
-        printrun
-    ];
-}
diff --git a/modules/python.nix b/modules/python.nix
deleted file mode 100644
index 5ba716d..0000000
--- a/modules/python.nix
+++ /dev/null
@@ -1,6 +0,0 @@
-{ pkgs, ... }: {
-  environment.systemPackages = with pkgs; [
-    python311
-    virtualenv
-  ];
-}
diff --git a/modules/rust.nix b/modules/rust.nix
deleted file mode 100644
index 1e1490b..0000000
--- a/modules/rust.nix
+++ /dev/null
@@ -1,5 +0,0 @@
-{ pkgs, ... }: {
-  home-manager.users.coded.home.packages = with pkgs; [
-    bacon
-  ];
-}
diff --git a/modules/yubikey.nix b/modules/yubikey.nix
deleted file mode 100644
index 752b77b..0000000
--- a/modules/yubikey.nix
+++ /dev/null
@@ -1,3 +0,0 @@
-{ pkgs, ... }: {
-  home-manager.users.coded.home.packages = with pkgs; [ yubikey-manager ];
-}