nixos/modules/hosts/robin/configuration.nix
2026-06-08 15:57:00 -04:00

82 lines
1.8 KiB
Nix

{ self, inputs, ... }: {
flake.nixosModules.robinConfiguration = { pkgs, ... }: {
imports = [
self.nixosModules.robinHardware
self.nixosModules.nest
self.nixosModules.git
self.nixosModules.zsh
];
environment.systemPackages = with pkgs; [
kubectl
htop
zip
unzip
dig
traceroute
neovim
wget
];
networking.networkmanager.enable = true;
networking.hostName = "robin";
services = {
openssh.enable = true;
};
services.nfs = {
server.enable = true;
server.exports = ''
/export/yarr 192.168.1.0/16(rw,secure,anonuid=1000,anongid=1000,all_squash)
/export 192.168.1.0/16(ro,fsid=0,root_squash,subtree_check,secure)
'';
};
# RAID
boot.swraid = {
enable = true;
mdadmConf = ''
ARRAY /dev/md0 level=raid10 num-devices=4 metadata=1.2 UUID=f94b90a5:574f242f:00596ed9:a2b369c7
'';
};
fileSystems."/mnt/raid" = {
device = "/dev/disk/by-uuid/208bee23-4723-42c2-ac4e-c902eb530f80";
fsType = "ext4";
options = [ "defaults" "nofail" "_netdev" ];
};
fileSystems."/export/yarr" = {
device = "/mnt/raid/yarr";
options = [ "bind" ];
};
boot = {
loader = {
systemd-boot.enable = true;
efi.canTouchEfiVariables = true;
timeout = 1;
};
kernelPackages = pkgs.linuxPackages_latest;
supportedFilesystems = [ "nfs" ];
};
time.timeZone = "America/New_York";
time.hardwareClockInLocalTime = false;
nix.settings.experimental-features = [ "nix-command" "flakes" ];
nix.settings.auto-optimise-store = true;
nix.gc = {
automatic = true;
dates = "weekly";
options = "--delete-older-than 30d";
};
nixpkgs.config.allowUnfree = true;
system.stateVersion = "26.05";
};
}