{ ... }: { pkgs, config, ... }: { imports = [ # "${nixpkgs}/nixos/modules/installer/sd-card/sd-image-aarch64.nix" # nixos-hardware.nixosModules.raspberry-pi-4 ../../users/root ../../users/erwin ./home.nix ]; eboskma = { users.erwin = { enable = true; }; desktop = { enable = false; }; fonts = { enable = false; iosevka-aile = false; }; gnome.enable = false; klipper.enable = true; lightdm.enable = false; networking.enable = true; nix-common = { enable = true; remote-builders = true; }; systemd.enable = true; }; # nixpkgs.crossSystem.system = "aarch64-linux"; hardware = { # deviceTree.filter = "bcm2711-rpi-4-b.dtb"; enableAllFirmware = true; # raspberry-pi."4".fkms-3d = { # enable = false; # cma = 512; # }; }; boot = { bootspec.enable = true; growPartition = true; loader = { efi.canTouchEfiVariables = true; systemd-boot = { enable = true; configurationLimit = 10; }; grub.enable = false; }; kernelPackages = pkgs.linuxPackages_latest; kernelParams = [ "console=ttyS0,115200n8" "console=ttyAMA0,115200n8" "console=tty0" "cma=512M" ]; initrd.availableKernelModules = [ # Allows early (earlier) modesetting for the Raspberry Pi "vc4" "bcm2835_dma" "i2c_bcm2835" # Maybe needed for SSD boot? "usb_storage" "xhci_pci" "usbhid" "uas" ]; }; fileSystems = { "/" = { device = "/dev/disk/by-label/nixos"; fsType = "ext4"; }; "/boot" = { device = "/dev/disk/by-label/EFI"; fsType = "vfat"; }; }; swapDevices = [ { device = "/dev/disk/by-label/swap"; } ]; powerManagement = { cpuFreqGovernor = "ondemand"; }; zramSwap.enable = true; # sdImage.compressImage = false; time.timeZone = "Europe/Amsterdam"; networking = { hostName = "thor"; useDHCP = true; useNetworkd = true; wireless.enable = true; }; systemd.network = { enable = true; networks = { "40-eth0" = { DHCP = "yes"; }; }; }; services = { openssh.enable = true; tailscale.enable = true; kanata = { enable = false; keyboards = { code = { devices = [ "/dev/input/by-id/usb-04d9_USB_Keyboard-event-kbd" ]; config = '' (defsrc esc f1 f2 f3 f4 f5 f6 f7 f8 f9 f10 f11 f12 prtsc scrlck pp grv 1 2 3 4 5 6 7 8 9 0 - = bspc ins home pgup tab q w e r t y u i o p [ ] \ del end pgdn caps a s d f g h j k l ; ' ret lsft z x c v b n m , . / rsft up lctl lmet lalt spc ralt rmet rctl lft down rght) (deflayer colemak esc f1 f2 f3 f4 f5 f6 f7 f8 f9 f10 f11 f12 prtsc @qwe pp grv 1 2 3 4 5 6 7 8 9 0 - = bspc ins home pgup tab q w f p g j l u y ; [ ] \ del end pgdn @cap a r s t d h n e i o ' ret lsft z x c v b k m , . / rsft up lctl lmet lalt spc ralt rmet rctl lft down rght) (deflayer qwerty esc f1 f2 f3 f4 f5 f6 f7 f8 f9 f10 f11 f12 prtsc @col pp grv 1 2 3 4 5 6 7 8 9 0 - = bspc ins home pgup tab q w e r t y u i o p [ ] \ del end pgdn @cap a s d f g h j k l ; ' ret lsft z x c v b n m , . / rsft up lctl lmet lalt spc ralt rmet rctl lft down rght) (defalias cap (tap-hold 100 100 bspc lctl) col (layer-switch colemak) qwe (layer-switch qwerty) ) ''; }; }; }; # xserver = { # enable = true; # windowManager.i3 = { # enable = true; # extraPackages = with pkgs; [ i3lock-color ]; # }; # }; }; security = { polkit.enable = true; }; environment.systemPackages = with pkgs; [ libraspberrypi raspberrypi-eeprom ]; system.stateVersion = "24.11"; }