homelab/hosts/zimablade/configuration.nix
2025-09-18 08:28:44 +02:00

92 lines
1.8 KiB
Nix

{
modulesPath,
lib,
pkgs,
...
}:
{
imports = [
(modulesPath + "/installer/scan/not-detected.nix")
(modulesPath + "/profiles/qemu-guest.nix")
./luks-btrfs-raid.nix
./jellyfin.nix
./transmission.nix
./homepage.nix
./glances.nix
./secrets.nix
./coredns
./gitea.nix
./copyparty.nix
];
boot.initrd.kernelModules = [ "usb_storage" ];
boot.loader.grub = {
# devices = [ ];
efiSupport = true;
efiInstallAsRemovable = true;
};
networking = {
hostName = "sin";
nameservers = [ "10.0.0.4" ];
dhcpcd.extraConfig = "nohook resolv.conf";
firewall = {
allowedTCPPorts = [
8000
8001
3000 # gitea
53
];
allowedUDPPorts = [ 53 ];
};
};
time.timeZone = "Europe/Paris";
nix.settings.experimental-features = [ "nix-command" "flakes" ];
nixpkgs.config.allowUnfree = true;
users.users = {
zimablade = {
isNormalUser = true;
extraGroups = [ "wheel" ];
openssh.authorizedKeys.keys = [ "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKsu+4S+BHmypQTq2IR9y+ihvbF7sXbBznKtIjVAeHJ1 shobu@nixos" ];
};
shobu = {
isNormalUser = true;
openssh.authorizedKeys.keys = [ "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKsu+4S+BHmypQTq2IR9y+ihvbF7sXbBznKtIjVAeHJ1 shobu@nixos" ];
};
};
users.users.root.openssh.authorizedKeys.keys = [
# change this to your ssh key
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKsu+4S+BHmypQTq2IR9y+ihvbF7sXbBznKtIjVAeHJ1 shobu@nixos"
];
environment.systemPackages = map lib.lowPrio [
pkgs.curl
pkgs.gitMinimal
] ++ (with pkgs; [
helix
httpie
btop
tmux
]);
services = {
openssh = {
enable = true;
ports = [ 22 ];
};
};
system.stateVersion = "24.11";
}