blob: c87aa445c29c4ac4711f707a36811ee60a0f72dd (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
|
# arbat is my Unchartevice 6640MA, with a Zhaoxin CPU.
{ depot, lib, pkgs, ... }:
config:
let
mod = name: depot.path.origSrc + ("/ops/modules/" + name);
usermod = name: depot.path.origSrc + ("/users/tazjin/nixos/modules/" + name);
zdevice = device: {
inherit device;
fsType = "zfs";
};
in
{
imports = [
(usermod "chromium.nix")
(usermod "desktop.nix")
(usermod "fonts.nix")
(usermod "home-config.nix")
(usermod "laptop.nix")
(usermod "persistence.nix")
(usermod "physical.nix")
(pkgs.home-manager.src + "/nixos")
];
tvl.cache.enable = true;
boot = {
loader.systemd-boot.enable = true;
supportedFilesystems = [ "zfs" ];
zfs.devNodes = "/dev/";
# TODO: double-check this list
initrd.availableKernelModules = [ "ahci" "uhci_hcd" "ehci_pci" "xhci_pci" "usb_storage" "sd_mod" "rtsx_usb_sdmmc" ];
kernelModules = [ "kvm-intel" ]; # interesting
};
networking = {
hostName = "arbat";
hostId = "864f050b";
networkmanager.enable = true;
};
fileSystems = {
"/" = zdevice "zpool/ephemeral/root";
"/home" = zdevice "zpool/ephemeral/home";
"/persist" = zdevice "zpool/persistent/data" // { neededForBoot = true; };
"/nix" = zdevice "zpool/persistent/nix";
"/depot" = zdevice "zpool/persistent/depot";
"/boot" = {
device = "/dev/disk/by-uuid/B3B5-92F7";
fsType = "vfat";
};
};
hardware = {
enableRedistributableFirmware = true;
graphics.enable = true;
bluetooth.enable = true;
};
# TODO(tazjin): decide on this
services.libinput = {
enable = true;
# libinput thinks the touchpad is a mouse
mouse.naturalScrolling = false;
mouse.disableWhileTyping = true;
};
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
system.stateVersion = "24.11";
}
|