Skip to content

Commit

Permalink
Add configuration for raspberry pi 4
Browse files Browse the repository at this point in the history
  • Loading branch information
joinemm committed Jul 2, 2024
1 parent 1fe3822 commit dd8f4ac
Show file tree
Hide file tree
Showing 2 changed files with 51 additions and 0 deletions.
4 changes: 4 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,10 @@
inherit specialArgs;
modules = [./hosts/hetzner/monitoring/configuration.nix];
};
archimedes = nixpkgs.lib.nixosSystem {
inherit specialArgs;
modules = [./hosts/archimedes/configuration.nix];
};
};

formatter.x86_64-linux =
Expand Down
47 changes: 47 additions & 0 deletions hosts/archimedes/configuration.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
{
lib,
outputs,
inputs,
pkgs,
...
}: {
imports = lib.flatten [
(with outputs.nixosModules; [
common
locale
ssh-access
])
inputs.nixos-hardware.nixosModules.raspberry-pi-4
];

hardware.raspberry-pi."4" = {
fkms-3d.enable = true;
touch-ft5406.enable = true;
};

nixpkgs.hostPlatform = "aarch64-linux";
networking.hostName = "archimedes";

boot = {
kernelPackages = pkgs.linuxKernel.packages.linux_rpi4;
initrd.availableKernelModules = ["xhci_pci" "usbhid" "usb_storage"];
loader = {
grub.enable = false;
generic-extlinux-compatible.enable = true;
};
};

fileSystems = {
"/" = {
device = "/dev/disk/by-label/NIXOS_SD";
fsType = "ext4";
options = ["noatime"];
};
};

environment.systemPackages = with pkgs; [
busybox
];

system.stateVersion = "24.05";
}

0 comments on commit dd8f4ac

Please sign in to comment.