Add Jules' RockPro64

This commit is contained in:
Jimbo 2025-02-27 11:42:57 -05:00
parent 46ba563e2f
commit e11627bd8f
18 changed files with 155 additions and 5 deletions

View file

@ -17,6 +17,7 @@
system = {
desktop.enable = true;
lanzaboote.enable = true;
fancyboot.enable = true;
wireless.enable = true;
wireguard.client.enable = true;
libvirtd.enable = true;

View file

@ -16,6 +16,7 @@
system = {
desktop.enable = true;
lanzaboote.enable = true;
fancyboot.enable = true;
libvirtd.enable = true;
stateVersion = "24.11";
};

View file

@ -1,4 +1,4 @@
{ lib, pkgs, ... }:
{ pkgs, ... }:
{
boot = {
kernelPackages = pkgs.linuxPackages_hardened;

View file

@ -1,4 +1,4 @@
{ pkgs, ... }:
{ ... }:
{
boot.kernelParams = [
"radeon.cik_support=0"

View file

@ -18,6 +18,7 @@
system = {
desktop.enable = true;
lanzaboote.enable = true;
fancyboot.enable = true;
wireless.enable = true;
wireguard.client.enable = true;
stateVersion = "24.05";

21
hosts/rubble/default.nix Normal file
View file

@ -0,0 +1,21 @@
{ ... }:
{
imports = [
./disko
./hardware
./users
../../modules/system
];
networking = {
hostName = "rubble";
hostId = "3d16423a";
};
system = {
desktop.enable = true;
extlinux.enable = true;
wireguard.client.enable = true;
stateVersion = "24.11";
};
}

View file

@ -0,0 +1,90 @@
{ config, disko, ... }:
{
imports = [ disko.nixosModules.disko ];
disko.devices = {
disk = {
"${config.networking.hostName}" = {
type = "disk";
device = "/dev/mmcblk1";
content = {
type = "gpt";
partitions = {
ESP = {
priority = 1;
size = "2G";
type = "EF00";
content = {
type = "filesystem";
format = "vfat";
mountpoint = "/boot";
mountOptions = [ "umask=0077" ];
};
};
luks = {
size = "100%";
content = {
type = "luks";
name = "${config.networking.hostName}-disk";
settings.allowDiscards = true;
passwordFile = "/tmp/secret.key";
content = {
type = "lvm_pv";
vg = "${config.networking.hostName}";
};
};
};
};
};
};
};
lvm_vg = {
"${config.networking.hostName}" = {
type = "lvm_vg";
lvs = {
root = {
size = "100%";
content = {
type = "btrfs";
extraArgs = [ "-f" ];
subvolumes = {
"/root" = {
mountpoint = "/";
mountOptions = [ "compress=zstd" "noatime" "ssd" ];
};
"/prev" = {
mountpoint = "/prev";
mountOptions = [ "compress=zstd" "noatime" "ssd" "noexec" ];
};
"/nix" = {
mountpoint = "/nix";
mountOptions = [ "compress=zstd" "noatime" "ssd" ];
};
# Impermanence
"/persist" = {
mountpoint = "/persist";
mountOptions = [ "compress=zstd" "noatime" "ssd" ];
};
"/persist/.snapshots" = { };
"/persist/home/${config.sysusers.main}" = { };
"/persist/home/${config.sysusers.main}/.snapshots" = { };
};
};
};
swap = {
size = "4G";
content = {
type = "swap";
discardPolicy = "both";
};
};
};
};
};
};
# Needed for impermanence
fileSystems."/persist".neededForBoot = true;
}

View file

@ -0,0 +1,9 @@
{ config, lib, modulesPath, ... }:
{
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
boot.initrd.kernelModules = [ "ahci" "dm-snapshot" "mmc_core" "pcie_rockchip_host" "phy_rockchip_pcie" "rockchip_dfi" "rockchip_thermal" "rtc_rk808" "rockchip_saradc" "uas" "fusb302" ];
networking.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "aarch64-linux";
}

View file

@ -0,0 +1 @@
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIF4oyz5yAvmVZDdr3NL2AmlnCA6Z17b2Vj0FXj07DFiv jimbo@rubble

View file

@ -0,0 +1,4 @@
{ ... }:
{
imports = [ ./main ];
}

View file

@ -0,0 +1,7 @@
{ config, lib, ... }:
{
home-manager.users."${config.sysusers.main}".home = {
desktop.enable = true;
stateVersion = lib.mkForce config.system.stateVersion;
};
}