nixos/systems/warp.nix
Julian Sutter 7263c12bfc fix: Resolve warp configuration issues found during testing
- Add root filesystem configuration (placeholder for actual hardware)
- Disable Flatpak service (not needed for headless server)
- Add rtsx_pci_sdmmc module for NUC SD card reader support
- Configuration now passes dry-build validation
2026-02-03 22:47:19 -08:00

78 lines
2 KiB
Nix

{ config, lib, pkgs, modulesPath, ... }: {
networking.hostName = "warp";
# CPU Settings for 13th gen Intel Core
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
# Boot and kernel modules for Intel NUC
boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "nvme" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" ];
# File system configuration - placeholder for actual hardware
fileSystems."/" = {
device = "/dev/disk/by-label/nixos";
fsType = "ext4";
};
boot.initrd.kernelModules = [];
boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [];
# Server-specific kernel parameters
boot.kernelParams = [
"intel_iommu=on"
];
networking.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
# No graphics support needed for headless server
# Power management optimized for server use
powerManagement = {
enable = true;
cpuFreqGovernor = "ondemand";
};
# Thermal management
services.thermald.enable = true;
# Server-oriented settings
services.openssh = {
enable = true;
settings = {
PasswordAuthentication = false;
KbdInteractiveAuthentication = false;
PermitRootLogin = "no";
};
};
# Swap configuration
swapDevices = [
{
device = "/swapfile";
size = 8192;
priority = 0;
}
];
# Enable hardware monitoring
hardware.sensor.iio.enable = true;
# Network performance tuning for server use
boot.kernel.sysctl = {
"net.core.rmem_max" = 134217728;
"net.core.wmem_max" = 134217728;
"net.ipv4.tcp_rmem" = "4096 65536 134217728";
"net.ipv4.tcp_wmem" = "4096 65536 134217728";
"net.core.netdev_max_backlog" = 5000;
};
# Disable unnecessary services for server use
services.xserver.enable = lib.mkForce false;
services.pipewire.enable = lib.mkForce false;
services.flatpak.enable = lib.mkForce false;
# Enable container support for server services
virtualisation.docker.enable = true;
virtualisation.podman.enable = lib.mkDefault true;
}