1{
2 self,
3 config,
4 ...
5}: {
6 imports = [
7 ./home.nix
8 ./secrets.nix
9 ./notifier.nix
10 ./backups.nix
11 self.nixosModules.locale-en-gb
12 ];
13
14 networking.hostName = "nanpi";
15 system.stateVersion = "25.05";
16 time.timeZone = "America/Sao_Paulo";
17 myHardware.acer.aspire."A315-53".enable = true;
18
19 myNixOS = {
20 programs = {
21 lanzaboote.enable = true;
22 nix.enable = true;
23 };
24 profiles = {
25 base.enable = true;
26 server.enable = true;
27 backups.enable = true;
28 btrfs = {
29 enable = true;
30 deduplicate = true;
31 };
32 swap = {
33 enable = true;
34 size = 4096;
35 location = "/.swap";
36 };
37 arr.enable = true;
38 };
39 services = {
40 audiobookshelf.enable = true;
41 caddy.enable = true;
42 cloudflared.enable = true;
43 copyparty.enable = true;
44 dnsmasq.enable = true;
45 forgejo.enable = true;
46 glance.enable = true;
47 jellyfin.enable = true;
48 jellyseerr.enable = true;
49 karakeep.enable = false;
50 miniflux.enable = true;
51 ntfy.enable = true;
52 pds.enable = true;
53 privatebin.enable = true;
54 qbittorrent = {
55 enable = true;
56 webuiPort = config.mySnippets.tailnet.networkMap.qbittorrent.port;
57 openFirewall = true;
58 };
59 radicale.enable = true;
60 redlib.enable = true;
61 syncthing = {
62 enable = true;
63 certFile = config.age.secrets.syncthingCert.path;
64 keyFile = config.age.secrets.syncthingKey.path;
65 user = "ayla";
66 };
67 tailscale = {
68 enable = true;
69 enableCaddy = true;
70 operator = "ayla";
71 };
72 vaultwarden.enable = true;
73 webdav.enable = true;
74 };
75 };
76
77 myUsers = {
78 ayla = {
79 enable = true;
80 passwordFile = config.age.secrets.aylaPassword.path;
81 };
82 };
83
84 boot = {
85 initrd = {
86 availableKernelModules = [
87 "xhci_pci"
88 "ahci"
89 "usb_storage"
90 "sd_mod"
91 "rtsx_pci_sdmmc"
92 ];
93
94 luks.devices = {
95 crypted.device = "/dev/disk/by-uuid/d82fc855-f29a-4aef-90d4-da94c23d0ac1";
96 crypted_external.device = "/dev/disk/by-uuid/0e477648-92d6-4cf5-a0c5-8d0707b69935";
97 };
98 };
99
100 kernelParams = [
101 "consoleblank=30"
102 ];
103 };
104
105 fileSystems = {
106 "/" = {
107 device = "/dev/disk/by-uuid/97fd311a-2575-487e-be03-45dfa9c2db8a";
108 fsType = "btrfs";
109 options = ["subvol=/root" "compress=zstd" "noatime"];
110 };
111
112 "/home" = {
113 device = "/dev/disk/by-uuid/97fd311a-2575-487e-be03-45dfa9c2db8a";
114 fsType = "btrfs";
115 options = ["subvol=/home" "compress=zstd" "noatime"];
116 };
117
118 "/home/.snapshots" = {
119 device = "/dev/disk/by-uuid/97fd311a-2575-487e-be03-45dfa9c2db8a";
120 fsType = "btrfs";
121 options = ["subvol=/home/.snapshots" "compress=zstd" "noatime"];
122 };
123
124 "/nix" = {
125 device = "/dev/disk/by-uuid/97fd311a-2575-487e-be03-45dfa9c2db8a";
126 fsType = "btrfs";
127 options = ["subvol=/nix" "compress=zstd" "noatime"];
128 };
129
130 "/boot" = {
131 device = "/dev/disk/by-uuid/7D56-EE82";
132 fsType = "vfat";
133 options = ["fmask=0077" "dmask=0077"];
134 };
135
136 "/external1" = {
137 device = "/dev/disk/by-uuid/130ead1c-6642-45d5-9053-b6cb2df9c7e4";
138 fsType = "btrfs";
139 options = ["compress=zstd" "noatime"];
140 };
141 };
142}