diff --git a/flake.nix b/flake.nix index 39e42ed..24313a4 100644 --- a/flake.nix +++ b/flake.nix @@ -103,7 +103,7 @@ specialArgs = inputs; }; systems = { - nixos = { user = "user"; }; + NixVM = { user = "user"; }; Kell = { user = "user"; }; Aloria = { user = "user"; }; }; diff --git a/home/NixVM.nix b/home/NixVM.nix index 497c26c..fc68e7c 100644 --- a/home/NixVM.nix +++ b/home/NixVM.nix @@ -3,5 +3,8 @@ { imports = [ (import ./utils/common.nix { inherit inputs config pkgs; }) + ./ssh ]; + + programs.ssh.matchBlocks."*".identityFile = "/home/user/.secrets/SSH/NixVM/id_ed25519"; } diff --git a/home/utils/desktop.nix b/home/utils/desktop.nix index 01f600b..13ecd28 100644 --- a/home/utils/desktop.nix +++ b/home/utils/desktop.nix @@ -20,64 +20,4 @@ evince loupe ]; - - services.greetd = { - enable = true; - settings = rec { - initial_session = { - command = "Hyprland"; - user = "user"; - }; - default_session = initial_session; - }; - }; - - fonts.packages = with pkgs; [ - noto-fonts - noto-fonts-cjk - noto-fonts-emoji - iosevka - nerdfonts - roboto - font-awesome - ]; - - hardware.opengl = { - enable = true; - driSupport = true; - driSupport32Bit = true; - }; - - services.pipewire = { - enable = true; - alsa.enable = true; - alsa.support32Bit = true; - pulse.enable = true; - jack.enable = true; - }; - - hardware.bluetooth.settings = { - General = { - Experimental = true; - }; - }; - - # Calendar - # Add the server using gnome-online-accounts: - # nix-shell -p gnome.gnome-control-center --run "gnome-control-center" - # Just add the main webdav server and gnome-calendar will automatically pick up all available calendars. - programs.dconf.enable = true; - services.gnome.evolution-data-server.enable = true; - services.gnome.gnome-online-accounts.enable = true; - services.gnome.gnome-keyring.enable = true; - - hardware.bluetooth.enable = true; - hardware.bluetooth.powerOnBoot = true; - services.blueman.enable = true; - systemd.user.services.mpris-proxy = { - description = "Mpris proxy"; - after = [ "network.target" "sound.target" ]; - wantedBy = [ "default.target" ]; - serviceConfig.ExecStart = "${pkgs.bluez}/bin/mpris-proxy"; - }; } diff --git a/hosts/Aloria/default.nix b/hosts/Aloria/default.nix index 83a6d3a..e8834b9 100644 --- a/hosts/Aloria/default.nix +++ b/hosts/Aloria/default.nix @@ -3,6 +3,7 @@ imports = [ (import ../Common/default.nix { inherit inputs pkgs config; }) (import ../Common/nvidia.nix { inherit inputs pkgs config; }) + (import ../Common/desktop.nix { inherit inputs pkgs config; }) ]; hardware.opengl.extraPackages = [ pkgs.intel-compute-runtime diff --git a/hosts/Common/default.nix b/hosts/Common/default.nix index e939bb0..51a3281 100644 --- a/hosts/Common/default.nix +++ b/hosts/Common/default.nix @@ -1,6 +1,9 @@ { pkgs, ... }: { security.polkit.enable = true; + security.rtkit.enable = true; + programs.zsh.enable = true; + networking.firewall.enable = false; boot.loader.systemd-boot.memtest86.enable = true; boot.loader.systemd-boot.netbootxyz.enable = true; @@ -12,8 +15,6 @@ services.fwupd.enable = true; services.gvfs.enable = true; services.fstrim.enable = true; - programs.zsh.enable = true; - services.openssh = { enable = true; settings = { @@ -22,9 +23,6 @@ }; }; - networking.firewall.enable = false; - - security.rtkit.enable = true; environment.systemPackages = with pkgs; [ wget curl @@ -37,7 +35,6 @@ podman-tui docker-compose ]; - services.udev.packages = [ pkgs.yubikey-personalization ]; virtualisation.containers.enable = true; virtualisation = { diff --git a/hosts/Common/desktop.nix b/hosts/Common/desktop.nix new file mode 100644 index 0000000..5dea59c --- /dev/null +++ b/hosts/Common/desktop.nix @@ -0,0 +1,64 @@ +{ pkgs, ... }: +{ + services.udev.packages = [ pkgs.yubikey-personalization ]; + + hardware.opengl = { + enable = true; + driSupport = true; + driSupport32Bit = true; + }; + + fonts.packages = with pkgs; [ + noto-fonts + noto-fonts-cjk + noto-fonts-emoji + iosevka + nerdfonts + roboto + font-awesome + ]; + + services.greetd = { + enable = true; + settings = rec { + initial_session = { + command = "Hyprland"; + user = "user"; + }; + default_session = initial_session; + }; + }; + + # Calendar + # Add the server using gnome-online-accounts: + # nix-shell -p gnome.gnome-control-center --run "gnome-control-center" + # Just add the main webdav server and gnome-calendar will automatically pick up all available calendars. + programs.dconf.enable = true; + services.gnome.evolution-data-server.enable = true; + services.gnome.gnome-online-accounts.enable = true; + services.gnome.gnome-keyring.enable = true; + + services.pipewire = { + enable = true; + alsa.enable = true; + alsa.support32Bit = true; + pulse.enable = true; + jack.enable = true; + }; + + hardware.bluetooth.enable = true; + hardware.bluetooth.powerOnBoot = true; + services.blueman.enable = true; + systemd.user.services.mpris-proxy = { + description = "Mpris proxy"; + after = [ "network.target" "sound.target" ]; + wantedBy = [ "default.target" ]; + serviceConfig.ExecStart = "${pkgs.bluez}/bin/mpris-proxy"; + }; + hardware.bluetooth.settings = { + General = { + Experimental = true; + }; + }; + +} diff --git a/hosts/Kell/default.nix b/hosts/Kell/default.nix index 82e61e0..a58e0ac 100644 --- a/hosts/Kell/default.nix +++ b/hosts/Kell/default.nix @@ -2,7 +2,8 @@ { imports = [ - (import ../Common { inherit inputs pkgs; }) + (import ../Common/default.nix { inherit inputs pkgs; }) + (import ../Common/desktop.nix { inherit inputs pkgs config; }) ]; # AMD CPU diff --git a/hosts/NixVM/default.nix b/hosts/NixVM/default.nix index 4bf5d2b..fa3e75a 100644 --- a/hosts/NixVM/default.nix +++ b/hosts/NixVM/default.nix @@ -1,8 +1,6 @@ { inputs, config, pkgs, ... }: { imports = [ - (import ./common.nix { inherit inputs config pkgs; }) - ../ssh + (import ../Common/default.nix { inherit inputs config pkgs; }) ]; - programs.ssh.matchBlocks."*".identityFile = "/home/user/.secrets/SSH/NixVM/id_ed25519"; }