This commit is contained in:
Sicheng Pan 2026-02-16 22:00:15 -08:00
parent c47db92a88
commit e7c56b4d22
Signed by: macronova
GPG key ID: CE969670FB4B4A56
27 changed files with 107 additions and 202 deletions

View file

@ -40,6 +40,7 @@ with lib; {
prowlarr = 30784;
radarr = 37196;
sonarr = 32438;
tailscale = 62662;
vault = 25487;
};
description = ''
@ -97,11 +98,37 @@ with lib; {
The username across all devices.
'';
};
zfsPoolOptions = mkOption {
type = types.attrsOf types.str;
default = {
ashift = "12";
autotrim = "on";
listsnapshots = "on";
};
description = ''
The default options for ZFS pools.
'';
};
zfsRootFsOptions = mkOption {
type = types.attrsOf types.str;
default = {
acltype = "posix";
atime = "off";
compression = "zstd";
dnodesize = "auto";
mountpoint = "none";
normalization = "formD";
xattr = "sa";
};
description = ''
The default root filesystem options for ZFS pools.
'';
};
wildcard = mkOption {
type = types.str;
default = "0.0.0.0";
description = ''
The localhost address.
The wildcard address for binding to all interfaces.
'';
};
};

View file

@ -3,9 +3,10 @@
home-manager.nixosModules.default
sops-nix.nixosModules.default
./constants.nix
./network.nix
./nix.nix
./secrets.nix
./users.nix
./nix.nix
];
home-manager.sharedModules = [inputs.plasma-manager.homeModules.plasma-manager];

8
common/network.nix Normal file
View file

@ -0,0 +1,8 @@
{config, ...}: {
networking.nftables.enable = true;
services.tailscale = {
enable = true;
port = config.constants.port.tailscale;
};
}

View file

@ -1,4 +1,6 @@
{config, ...}: {
boot.tmp.cleanOnBoot = true;
nix = {
gc = {
automatic = true;

View file

@ -1,5 +1,6 @@
{
config,
lib,
pkgs,
...
}:
@ -239,7 +240,7 @@ in {
};
};
resolved.enable = true;
syncthing = {
syncthing = lib.mkIf config.services.syncthing.enable {
configDir = "${homeDir}/.config/syncthing";
dataDir = "${homeDir}/.local/share/syncthing";
openDefaultPorts = true;