diff --git a/flake.nix b/flake.nix index 7190ff3..f709798 100644 --- a/flake.nix +++ b/flake.nix @@ -25,7 +25,7 @@ system = "x86_64-linux"; modules = [ { nixpkgs.overlays = [ nur.overlay ]; } - ./configuration.nix + ./nixos agenix.nixosModules.default nixos-hardware.nixosModules.lenovo-thinkpad-x260 home-manager.nixosModules.home-manager { @@ -33,7 +33,7 @@ home-manager.useUserPackages = true; home-manager.users.pim = { imports = [ - ./home + ./home-manager homeage.homeManagerModules.homeage ]; }; diff --git a/home/README.md b/home-manager/README.md similarity index 100% rename from home/README.md rename to home-manager/README.md diff --git a/home/alacritty/config.nix b/home-manager/alacritty/config.nix similarity index 100% rename from home/alacritty/config.nix rename to home-manager/alacritty/config.nix diff --git a/home/alacritty/default.nix b/home-manager/alacritty/default.nix similarity index 100% rename from home/alacritty/default.nix rename to home-manager/alacritty/default.nix diff --git a/home/bash/default.nix b/home-manager/bash/default.nix similarity index 100% rename from home/bash/default.nix rename to home-manager/bash/default.nix diff --git a/home/default.nix b/home-manager/default.nix similarity index 100% rename from home/default.nix rename to home-manager/default.nix diff --git a/home/direnv/default.nix b/home-manager/direnv/default.nix similarity index 100% rename from home/direnv/default.nix rename to home-manager/direnv/default.nix diff --git a/home/firefox/addons.json b/home-manager/firefox/addons.json similarity index 100% rename from home/firefox/addons.json rename to home-manager/firefox/addons.json diff --git a/home/firefox/addons.nix b/home-manager/firefox/addons.nix similarity index 100% rename from home/firefox/addons.nix rename to home-manager/firefox/addons.nix diff --git a/home/firefox/custom-addons.nix b/home-manager/firefox/custom-addons.nix similarity index 100% rename from home/firefox/custom-addons.nix rename to home-manager/firefox/custom-addons.nix diff --git a/home/firefox/default.nix b/home-manager/firefox/default.nix similarity index 100% rename from home/firefox/default.nix rename to home-manager/firefox/default.nix diff --git a/home/fzf/default.nix b/home-manager/fzf/default.nix similarity index 100% rename from home/fzf/default.nix rename to home-manager/fzf/default.nix diff --git a/home/git/default.nix b/home-manager/git/default.nix similarity index 100% rename from home/git/default.nix rename to home-manager/git/default.nix diff --git a/home/keepassxc/config.nix b/home-manager/keepassxc/config.nix similarity index 100% rename from home/keepassxc/config.nix rename to home-manager/keepassxc/config.nix diff --git a/home/keepassxc/default.nix b/home-manager/keepassxc/default.nix similarity index 100% rename from home/keepassxc/default.nix rename to home-manager/keepassxc/default.nix diff --git a/home/neovim/default.nix b/home-manager/neovim/default.nix similarity index 100% rename from home/neovim/default.nix rename to home-manager/neovim/default.nix diff --git a/home/neovim/neovim.lua b/home-manager/neovim/neovim.lua similarity index 100% rename from home/neovim/neovim.lua rename to home-manager/neovim/neovim.lua diff --git a/home/ssh/default.nix b/home-manager/ssh/default.nix similarity index 100% rename from home/ssh/default.nix rename to home-manager/ssh/default.nix diff --git a/home/syncthing/default.nix b/home-manager/syncthing/default.nix similarity index 100% rename from home/syncthing/default.nix rename to home-manager/syncthing/default.nix diff --git a/home/syncthing/syncthing.xml b/home-manager/syncthing/syncthing.xml similarity index 100% rename from home/syncthing/syncthing.xml rename to home-manager/syncthing/syncthing.xml diff --git a/home/thunderbird/default.nix b/home-manager/thunderbird/default.nix similarity index 100% rename from home/thunderbird/default.nix rename to home-manager/thunderbird/default.nix diff --git a/configuration.nix b/nixos/default.nix similarity index 75% rename from configuration.nix rename to nixos/default.nix index f5a0860..67870f5 100644 --- a/configuration.nix +++ b/nixos/default.nix @@ -1,24 +1,29 @@ { pkgs, config, ... }: { - imports = - [ - ./hardware-configuration.nix - ]; + imports = [ + ./hardware-configuration.nix + ]; boot = { loader.systemd-boot.enable = true; }; - networking.hostName = "x260"; time.timeZone = "Europe/Amsterdam"; i18n.defaultLocale = "en_US.UTF-8"; - services.xserver = { - enable = true; - displayManager.gdm = { + services = { + xserver = { enable = true; + displayManager.gdm = { + enable = true; + }; + desktopManager.gnome.enable = true; + excludePackages = with pkgs; [ xterm ]; + }; + + printing = { + enable = true; + drivers = [ pkgs.hplip pkgs.gutenprint ]; }; - desktopManager.gnome.enable = true; - excludePackages = with pkgs; [ xterm ]; }; users = { @@ -84,12 +89,19 @@ }; }; - age.secrets.wg-quick-home-privkey.file = ./secrets/wg-quick-home-privkey.age; - age.secrets.wg-quick-home-preshared-key.file = ./secrets/wg-quick-home-preshared-key.age; - age.identityPaths = [ "/home/pim/.ssh/age_ed25519" ]; + age = { + identityPaths = [ "/home/pim/.ssh/age_ed25519" ]; - networking.wg-quick = { - interfaces.home = { + secrets = { + wg-quick-home-privkey.file = ../secrets/wg-quick-home-privkey.age; + wg-quick-home-preshared-key.file = ../secrets/wg-quick-home-preshared-key.age; + }; + }; + + networking = { + hostName = "x260"; + + wg-quick.interfaces.home = { privateKeyFile = config.age.secrets.wg-quick-home-privkey.path; address = [ "10.225.191.4/24" @@ -115,7 +127,4 @@ setSocketVariable = true; }; }; - - services.printing.enable = true; - services.printing.drivers = [ pkgs.hplip pkgs.gutenprint ]; } diff --git a/hardware-configuration.nix b/nixos/hardware-configuration.nix similarity index 100% rename from hardware-configuration.nix rename to nixos/hardware-configuration.nix