big restructure, getting there prayers for rebuild

This commit is contained in:
2025-10-13 21:29:04 -05:00
parent 9128bf3d66
commit c02dafd0d1
26 changed files with 82 additions and 63 deletions

View File

@@ -25,31 +25,31 @@ in
tailscale.enable = true;
nvidia.enable = true;
};
homelab = {
enable = true;
fileshare = {
zfs.enable = true;
smb.enable = true;
nfs.enable = true;
};
homelab.enable = true;
services = {
caddy.enable = true;
gitea.enable = true;
glance.enable = true;
immich.enable = true;
hass.enable = true;
jellyfin.enable = true;
audiobookshelf.enable = true;
yacreader.enable = true;
vaultwarden.enable = true;
gitea.enable = true;
glance.enable = true;
qbittorrent.enable = true;
immich.enable = true;
hass.enable = true;
zigbee2mqtt.enable = true;
mosquitto.enable = true;
sonarr.enable = true;
radarr.enable = true;
bazarr.enable = true;
prowlarr.enable = true;
flaresolverr.enable = true;
bazarr.enable = true;
radarr.enable = true;
sonarr.enable = true;
zigbee2mqtt.enable = true;
mosquitto.enable = true;
caddy.enable = true;
uptime-kuma.enable = true;
vaultwarden.enable = true;
};
gameservers = {
minecraft_recpro.enable = true;

View File

@@ -39,11 +39,27 @@ in
};
};
# the order determines the order in glance :3
imports = [
./services
./shares/nfs.nix
./shares/smb.nix
./shares/zfs.nix
./fileshare
./caddy
./home/zigbee2mqtt
./vaultwarden
./gitea
./home/homeassistant
./immich
./arr/bazarr
./arr/prowlarr
./arr/radarr
./qbittorrent
./arr/sonarr
./yacreader
./audiobookshelf
./jellyfin
./arr/flaresolverr
./home/mosquitto
./uptime-kuma
./glance
];
config = lib.mkIf cfg.enable {

View File

@@ -0,0 +1,13 @@
{
pkgs,
config,
lib,
...
}: {
# services show up in glance in reverse import order lmao
imports = [
./shares/nfs.nix
./shares/smb.nix
./shares/zfs.nix
];
}

View File

@@ -1,14 +1,17 @@
{ pkgs, config, lib, ... }:
{
pkgs,
config,
lib,
...
}:
# define nfs exports
let
cfg = config.modules.homelab.nfs;
cfg = config.modules.fileshare.nfs;
nfs_exports = ''
/holocron/vault *(rw,sync,no_subtree_check,no_root_squash)
/holocron/media *(ro,sync,no_subtree_check)
'';
in
{
#/holocron/vault *(rw,sync,no_subtree_check,no_root_squash)
in {
options.modules.homelab.nfs = {
enable = lib.mkEnableOption "enables nfs";
};

View File

@@ -1,8 +1,12 @@
{ pkgs, config, lib, ... }:
{
pkgs,
config,
lib,
...
}:
# define smb shares
let
cfg = config.modules.homelab.smb;
cfg = config.modules.fileshare.smb;
smb_shares = {
vault = {
path = "/holocron/vault";
@@ -17,8 +21,7 @@ let
guestOk = false;
};
};
in
{
in {
options.modules.homelab.smb = {
enable = lib.mkEnableOption "enables smb";
};

View File

@@ -1,9 +1,11 @@
{ pkgs, config, lib, ... }:
let
cfg = config.modules.homelab.zfs;
in
{
pkgs,
config,
lib,
...
}: let
cfg = config.modules.fileshare.zfs;
in {
options.modules.homelab.zfs = {
enable = lib.mkEnableOption "enables zfs";
};
@@ -31,5 +33,4 @@ in
options = ["nofail"];
};
};
}

View File

@@ -293,5 +293,14 @@ in
paths = [ cfg.data_dir ];
};
};
# add to udr to glance
modules.services.glance.links.system = [{
title = "bebe";
url = "https://bebe.lan";
error-url = "https://10.10.0.1";
check-url = "https://10.10.0.1";
icon = "di:unifi";
allow-insecure = true; }];
};
}

View File

@@ -5,34 +5,8 @@
# services show up in glance in reverse import order lmao
imports = [
./home/zigbee2mqtt
./vaultwarden
./gitea
./home/homeassistant
./immich
./arr/bazarr
./arr/prowlarr
./arr/radarr
./qbittorrent
./arr/sonarr
./yacreader
./audiobookshelf
./jellyfin
./caddy
./arr/flaresolverr
./home/mosquitto
./uptime-kuma
./glance
];
# add to udr to glance
modules.services.glance.links.system = [{
title = "bebe";
url = "https://bebe.lan";
error-url = "https://10.10.0.1";
check-url = "https://10.10.0.1";
icon = "di:unifi";
allow-insecure = true; }];