bwaaa
This commit is contained in:
@@ -1,10 +1,10 @@
|
||||
{ inputs, ... }:
|
||||
{ inputs, lib, ... }:
|
||||
{
|
||||
imports = [ inputs.disko.nixosModules.disko ];
|
||||
disko.devices = {
|
||||
disk = {
|
||||
main = {
|
||||
device = "/dev/mmcblk0";
|
||||
device = "/dev/disk/by-label/NIXOS_SD";
|
||||
type = "disk";
|
||||
content = {
|
||||
type = "gpt";
|
||||
@@ -36,25 +36,10 @@
|
||||
root = {
|
||||
size = "100%";
|
||||
content = {
|
||||
type = "btrfs";
|
||||
extraArgs = [ "-f" ]; # Override existing partition
|
||||
# Subvolumes must set a mountpoint in order to be mounted,
|
||||
# unless their parent is mounted
|
||||
subvolumes = {
|
||||
# Subvolume name is different from mountpoint
|
||||
"@" = {
|
||||
type = "filesystem";
|
||||
format = "ext4";
|
||||
mountpoint = "/";
|
||||
};
|
||||
# Subvolume name is the same as the mountpoint
|
||||
"@home" = {
|
||||
mountpoint = "/home";
|
||||
};
|
||||
# Parent is not mounted so the mountpoint must be set
|
||||
"@nix" = {
|
||||
mountpoint = "/nix";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,7 +1,36 @@
|
||||
{ lib, inputs, ... }:
|
||||
{
|
||||
lib,
|
||||
inputs,
|
||||
modulesPath,
|
||||
...
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
./disks.nix
|
||||
# ./disks.nix
|
||||
inputs.nixos-hardware.nixosModules.raspberry-pi-4
|
||||
(modulesPath + "/installer/sd-card/sd-image-aarch64.nix")
|
||||
];
|
||||
fileSystems = {
|
||||
"/" = {
|
||||
device = "/dev/disk/by-label/NIXOS_SD";
|
||||
fsType = "ext4";
|
||||
options = [ "noatime" ];
|
||||
};
|
||||
};
|
||||
boot.supportedFilesystems = lib.mkForce [
|
||||
"btrfs"
|
||||
"reiserfs"
|
||||
"vfat"
|
||||
"ext4"
|
||||
"f2fs"
|
||||
"xfs"
|
||||
"ntfs"
|
||||
"cifs"
|
||||
];
|
||||
nixpkgs.overlays = [
|
||||
# https://github.com/NixOS/nixpkgs/issues/126755#issuecomment-869149243
|
||||
(final: super: {
|
||||
makeModulesClosure = x: super.makeModulesClosure (x // { allowMissing = true; });
|
||||
})
|
||||
];
|
||||
}
|
||||
|
||||
@@ -120,6 +120,7 @@ in
|
||||
|
||||
services.libinput.enable = true;
|
||||
|
||||
boot.binfmt.emulatedSystems = [ "aarch64-linux" ];
|
||||
# Define a user account. Don't forget to set a password with ‘passwd’.
|
||||
users.users.doloro = {
|
||||
isNormalUser = true;
|
||||
@@ -135,6 +136,7 @@ in
|
||||
# initialPassword = "sex";
|
||||
};
|
||||
users.mutableUsers = false;
|
||||
services.system76-scheduler.enable = true;
|
||||
|
||||
# programs.firefox.enable = true;
|
||||
|
||||
|
||||
@@ -1,7 +1,40 @@
|
||||
{ lib, inputs, ... }:
|
||||
{
|
||||
imports = [
|
||||
./disks.nix
|
||||
inputs.nixos-hardware.nixosModules.raspberry-pi-4
|
||||
lib,
|
||||
pkgs,
|
||||
inputs,
|
||||
...
|
||||
}:
|
||||
{
|
||||
users = {
|
||||
mutableUsers = false;
|
||||
users.doloro = {
|
||||
isNormalUser = true;
|
||||
extraGroups = [ "wheel" ];
|
||||
openssh.authorizedKeys.keys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIE/4h+WCBBW82puv8SMdUbkWymF4amEMuZitgFztB6oZ" # laptop pub key
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIBaa6Z5qtBSLEz+A4fQGYPfkOISsRQlmKkVbcx2zxML7" # pc pub key
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
networking.hostName = "nixos-001-rp5";
|
||||
|
||||
services.openssh.enable = true;
|
||||
|
||||
boot = {
|
||||
kernelPackages = pkgs.linuxKernel.packages.linux_rpi4;
|
||||
initrd.availableKernelModules = [
|
||||
"xhci_pci"
|
||||
"usbhid"
|
||||
"usb_storage"
|
||||
];
|
||||
loader = {
|
||||
grub.enable = false;
|
||||
generic-extlinux-compatible.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
hardware.enableRedistributableFirmware = true;
|
||||
system.stateVersion = "25.11";
|
||||
nixpkgs.hostPlatform = "aarch64-linux";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user