diff --git a/flake.nix b/flake.nix index 1eff13e9..d4364ffd 100644 --- a/flake.nix +++ b/flake.nix @@ -116,7 +116,7 @@ bolty = mkServer nixpkgs-stable "x86_64-linux" "bolty"; vultr1 = mkServer nixpkgs-stable "x86_64-linux" "vultr1"; vpsfree1 = mkServer nixpkgs-stable "x86_64-linux" "vpsfree1"; - rpi4_8 = mkRaspi nixpkgs-stable "rpi4-8"; + homescreen = mkRaspi nixpkgs-stable "homescreen"; bootstrap = nixpkgs-stable.lib.nixosSystem rec { system = "x86_64-linux"; @@ -137,12 +137,30 @@ (import "${inputs.nixpkgs-nixos-unstable}/nixos/modules/installer/sd-card/sd-image-aarch64-installer.nix") { + environment.systemPackages = + with nixpkgs-nixos-unstable.legacyPackages."aarch64-linux"; [ + neovim + htop + btop + atop + ]; + + networking = { networkmanager = { enable = false; }; }; + services.fail2ban.enable = true; + services.openssh = { enable = true; permitRootLogin = - inputs.nixpkgs-stable.lib.mkForce "prohibit-password"; + nixpkgs-stable.lib.mkForce "prohibit-password"; passwordAuthentication = false; }; + + services.xserver = { + enable = true; + displayManager.gdm.enable = true; + desktopManager.gnome.enable = true; + }; + users.extraUsers.root.openssh.authorizedKeys.keys = [ "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIEo4R+6J3h6Ix3xWpOMdU7Es1/YxFchHw0c+kcCOJxFb cyryl@foureighty" ]; diff --git a/nixos/boxes/homescreen/default.nix b/nixos/boxes/homescreen/default.nix index 7df76cc8..8a602bc9 100644 --- a/nixos/boxes/homescreen/default.nix +++ b/nixos/boxes/homescreen/default.nix @@ -18,13 +18,13 @@ version = 4; }; boot.loader.grub.enable = false; - boot.loader.generic-extlinux-compatible.enable = true; + networking = { - hostName = "rpi4-8"; + hostName = "homescreen"; networkmanager = { enable = true; }; }; - environment.systemPackages = with pkgs; [ neovim htop ]; + environment.systemPackages = with pkgs; [ neovim htop btop atop ]; services.fail2ban.enable = true; @@ -34,8 +34,14 @@ passwordAuthentication = false; }; + services.xserver = { + enable = true; + displayManager.gdm.enable = true; + desktopManager.gnome.enable = true; + }; + users.extraUsers.root.openssh.authorizedKeys.keys = [ - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIE5Ejx5CAPUfHVXi4GL4WmnZaG8eiiOmsW/a0o1bs1GF cyryl@foureighty" + "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIEo4R+6J3h6Ix3xWpOMdU7Es1/YxFchHw0c+kcCOJxFb cyryl@foureighty" ]; fileSystems = { "/" = { @@ -49,5 +55,6 @@ security.allowUserNamespaces = true; time.timeZone = "Europe/London"; + system.stateVersion = "22.05"; }