306 current 2025-10-11 17:04:37 25.05.20251006.20c4598 6.12.50 *
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
# flake for blakes nixos config
|
# flake for blakes nixos config
|
||||||
# define new devices in outputs
|
# define new devices in outputs
|
||||||
# generation: 305 current 2025-10-11 16:58:36 25.05.20251006.20c4598 6.12.50 *
|
# generation: 306 current 2025-10-11 17:04:37 25.05.20251006.20c4598 6.12.50 *
|
||||||
{
|
{
|
||||||
description = "blakes nix config";
|
description = "blakes nix config";
|
||||||
inputs = {
|
inputs = {
|
||||||
|
|||||||
@@ -81,6 +81,14 @@ in
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# add to glance
|
||||||
|
modules.services.glance.links.mediastack = [{
|
||||||
|
title = service;
|
||||||
|
url = "https://${cfg.url}";
|
||||||
|
error-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||||
|
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||||
|
icon = "di:${service}"; }];
|
||||||
|
|
||||||
# add to backups
|
# add to backups
|
||||||
modules.system.backups.baks = {
|
modules.system.backups.baks = {
|
||||||
${service} = { paths = [ cfg.data_dir ]; };
|
${service} = { paths = [ cfg.data_dir ]; };
|
||||||
|
|||||||
@@ -89,8 +89,7 @@ in
|
|||||||
url = "https://${cfg.url}";
|
url = "https://${cfg.url}";
|
||||||
error-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
error-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||||
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||||
icon = "di:${service}";
|
icon = "di:${service}"; }];
|
||||||
allow-insecure = false; }];
|
|
||||||
|
|
||||||
# add to backups
|
# add to backups
|
||||||
modules.system.backups.baks = {
|
modules.system.backups.baks = {
|
||||||
|
|||||||
@@ -92,8 +92,7 @@ in
|
|||||||
url = "https://${cfg.url}";
|
url = "https://${cfg.url}";
|
||||||
error-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
error-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||||
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||||
icon = "di:${service}";
|
icon = "di:${service}"; }];
|
||||||
allow-insecure = true; }];
|
|
||||||
|
|
||||||
# add to backups
|
# add to backups
|
||||||
modules.system.backups.baks = {
|
modules.system.backups.baks = {
|
||||||
|
|||||||
@@ -90,8 +90,7 @@ in
|
|||||||
url = "https://${cfg.url}";
|
url = "https://${cfg.url}";
|
||||||
error-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
error-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||||
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||||
icon = "di:${service}";
|
icon = "di:${service}"; }];
|
||||||
allow-insecure = true; }];
|
|
||||||
|
|
||||||
# add to backups
|
# add to backups
|
||||||
modules.system.backups.baks = {
|
modules.system.backups.baks = {
|
||||||
|
|||||||
@@ -115,6 +115,14 @@ in
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# add to glance
|
||||||
|
modules.services.glance.links.service = [{
|
||||||
|
title = service;
|
||||||
|
url = "https://git.${home.base_domain}";
|
||||||
|
error-url = "http://${cfg.url}:${toString cfg.port}";
|
||||||
|
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||||
|
icon = "di:${service}"; }];
|
||||||
|
|
||||||
# add to backups
|
# add to backups
|
||||||
modules.system.backups.baks = {
|
modules.system.backups.baks = {
|
||||||
${service} = { paths = [ cfg.data_dir ]; };
|
${service} = { paths = [ cfg.data_dir ]; };
|
||||||
|
|||||||
@@ -53,11 +53,21 @@ in
|
|||||||
description = "enable backups for ${service}";
|
description = "enable backups for ${service}";
|
||||||
};
|
};
|
||||||
links = {
|
links = {
|
||||||
|
services = lib.mkOption {
|
||||||
|
type = lib.types.listOf lib.types.attrs;
|
||||||
|
default = [];
|
||||||
|
description = "list of links for ${service}";
|
||||||
|
};
|
||||||
mediastack = lib.mkOption {
|
mediastack = lib.mkOption {
|
||||||
type = lib.types.listOf lib.types.attrs;
|
type = lib.types.listOf lib.types.attrs;
|
||||||
default = [];
|
default = [];
|
||||||
description = "list of links for ${service}";
|
description = "list of links for ${service}";
|
||||||
};
|
};
|
||||||
|
system = lib.mkOption {
|
||||||
|
type = lib.types.listOf lib.types.attrs;
|
||||||
|
default = [];
|
||||||
|
description = "list of links for ${service}";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -123,8 +133,8 @@ in
|
|||||||
{
|
{
|
||||||
type = "monitor";
|
type = "monitor";
|
||||||
cache = "1m";
|
cache = "1m";
|
||||||
title = "mediastack";
|
title = "services";
|
||||||
sites = cfg.links.mediastack;
|
sites = cfg.links.services;
|
||||||
# sites = [
|
# sites = [
|
||||||
# { title = "jellyfin"; url = "https://media.blakedheld.xyz"; icon = "di:jellyfin"; }
|
# { title = "jellyfin"; url = "https://media.blakedheld.xyz"; icon = "di:jellyfin"; }
|
||||||
# { title = "audiobookshelf"; url = "https://audiobooks.blakedheld.xyz"; icon = "di:audiobookshelf"; }
|
# { title = "audiobookshelf"; url = "https://audiobooks.blakedheld.xyz"; icon = "di:audiobookshelf"; }
|
||||||
@@ -140,29 +150,31 @@ in
|
|||||||
{
|
{
|
||||||
type = "monitor";
|
type = "monitor";
|
||||||
cache = "1m";
|
cache = "1m";
|
||||||
title = "services";
|
title = "mediastack";
|
||||||
sites = [
|
sites = cfg.links.mediastack;
|
||||||
{ title = "immich"; url = "https://pics.blakedheld.xyz"; icon = "di:immich"; }
|
# [
|
||||||
{ title = "vaultwarden"; url = "https://pass.blakedheld.xyz"; icon = "di:vaultwarden"; }
|
# { title = "immich"; url = "https://pics.blakedheld.xyz"; icon = "di:immich"; }
|
||||||
{ title = "gitea"; url = "https://git.blakedheld.xyz"; icon = "di:gitea"; }
|
# { title = "vaultwarden"; url = "https://pass.blakedheld.xyz"; icon = "di:vaultwarden"; }
|
||||||
{ title = "home assistant"; url = "https://home.blakedheld.xyz"; icon = "di:home-assistant"; }
|
# { title = "gitea"; url = "https://git.blakedheld.xyz"; icon = "di:gitea"; }
|
||||||
{ title = "zigbee2mqtt"; url = "http://10.10.0.30:4142"; icon = "di:zigbee2mqtt"; }
|
# { title = "home assistant"; url = "https://home.blakedheld.xyz"; icon = "di:home-assistant"; }
|
||||||
{ title = "syncthing"; url = "http://10.10.0.20:2222"; icon = "di:syncthing"; }
|
# { title = "zigbee2mqtt"; url = "http://10.10.0.30:4142"; icon = "di:zigbee2mqtt"; }
|
||||||
{ title = "archivebox"; url = "http://10.10.0.30:5656"; icon = "sh:archivebox"; }
|
# { title = "syncthing"; url = "http://10.10.0.20:2222"; icon = "di:syncthing"; }
|
||||||
{ title = "copyparty"; url = "http://10.10.0.20:3923"; icon = "sh:copyparty"; }
|
# { title = "archivebox"; url = "http://10.10.0.30:5656"; icon = "sh:archivebox"; }
|
||||||
];
|
# { title = "copyparty"; url = "http://10.10.0.20:3923"; icon = "sh:copyparty"; }
|
||||||
|
# ];
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
type = "monitor";
|
type = "monitor";
|
||||||
cache = "1m";
|
cache = "1m";
|
||||||
title = "system";
|
title = "system";
|
||||||
sites = [
|
sites = cfg.links.system;
|
||||||
{ title = "proxmox"; url = "http://10.10.0.10:8006"; icon = "di:proxmox"; allow-insecure = true; }
|
# [
|
||||||
{ title = "nginx"; url = "http://10.10.0.30:8080"; icon = "di:nginx"; }
|
# { title = "proxmox"; url = "http://10.10.0.10:8006"; icon = "di:proxmox"; allow-insecure = true; }
|
||||||
{ title = "uptime kuma"; url = "http://10.10.0.30:8181"; icon = "di:uptime-kuma"; }
|
# { title = "nginx"; url = "http://10.10.0.30:8080"; icon = "di:nginx"; }
|
||||||
{ title = "tn holocron"; url = "https://10.10.0.20"; icon = "di:truenas"; allow-insecure = true; }
|
# { title = "uptime kuma"; url = "http://10.10.0.30:8181"; icon = "di:uptime-kuma"; }
|
||||||
{ title = "bebe"; url = "https://10.10.0.1"; icon = "di:unifi"; allow-insecure = true; }
|
# { title = "tn holocron"; url = "https://10.10.0.20"; icon = "di:truenas"; allow-insecure = true; }
|
||||||
];
|
# { title = "bebe"; url = "https://10.10.0.1"; icon = "di:unifi"; allow-insecure = true; }
|
||||||
|
# ];
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -96,6 +96,14 @@ in
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# add to glance
|
||||||
|
modules.services.glance.links.service = [{
|
||||||
|
title = service;
|
||||||
|
url = "https://photos.${homelab.base_domain}";
|
||||||
|
error-url = "http://${cfg.url}:${toString cfg.port}";
|
||||||
|
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||||
|
icon = "di:${service}"; }];
|
||||||
|
|
||||||
# add to backups
|
# add to backups
|
||||||
modules.system.backups.baks = {
|
modules.system.backups.baks = {
|
||||||
${service} = { paths = [ cfg.data_dir "/var/lib/redis-immich" ]; };
|
${service} = { paths = [ cfg.data_dir "/var/lib/redis-immich" ]; };
|
||||||
|
|||||||
@@ -90,12 +90,13 @@ in
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
# sops.secrets = {
|
# add to glance
|
||||||
# "${service}_" = {
|
modules.services.glance.links.mediastack = [{
|
||||||
# owner = "${service}";
|
title = service;
|
||||||
# group = "${service}";
|
url = "https://media.${homelab.base_domain}";
|
||||||
# };
|
error-url = "http://${cfg.url}:${toString cfg.port}";
|
||||||
# };
|
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||||
|
icon = "di:${service}"; }];
|
||||||
|
|
||||||
# add to backups
|
# add to backups
|
||||||
modules.system.backups.baks = {
|
modules.system.backups.baks = {
|
||||||
|
|||||||
@@ -119,6 +119,14 @@ in
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# add to glance
|
||||||
|
modules.services.glance.links.mediastack = [{
|
||||||
|
title = service;
|
||||||
|
url = "https://${cfg.url}";
|
||||||
|
error-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||||
|
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||||
|
icon = "di:${service}"; }];
|
||||||
|
|
||||||
# add to backups
|
# add to backups
|
||||||
modules.system.backups.baks = {
|
modules.system.backups.baks = {
|
||||||
${service} = { paths = [ cfg.data_dir ]; };
|
${service} = { paths = [ cfg.data_dir ]; };
|
||||||
|
|||||||
@@ -137,6 +137,14 @@ in
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# add to glance
|
||||||
|
modules.services.glance.links.services = [{
|
||||||
|
title = service;
|
||||||
|
url = "https://hass.${homelab.base_domain}";
|
||||||
|
error-url = "http://${cfg.url}:${toString cfg.port}";
|
||||||
|
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||||
|
icon = "di:${service}"; }];
|
||||||
|
|
||||||
# add to backups
|
# add to backups
|
||||||
modules.system.backups.baks = {
|
modules.system.backups.baks = {
|
||||||
${service} = { paths = [ cfg.data_dir ]; };
|
${service} = { paths = [ cfg.data_dir ]; };
|
||||||
|
|||||||
@@ -64,9 +64,10 @@ in
|
|||||||
acl = [ "readwrite #" ];
|
acl = [ "readwrite #" ];
|
||||||
hashedPassword = "$7$101$140powz2MtsRawFT$ydndjal9wCAywIWtUEAh/IusdfDFvnHMupTFjdS7Ad/EjsEIbJgHrLY9waCe4Z3142XieuxMrXUDjMTp2qwyiw==";
|
hashedPassword = "$7$101$140powz2MtsRawFT$ydndjal9wCAywIWtUEAh/IusdfDFvnHMupTFjdS7Ad/EjsEIbJgHrLY9waCe4Z3142XieuxMrXUDjMTp2qwyiw==";
|
||||||
};
|
};
|
||||||
#settings.allow_anonymous = true;
|
# use with no auth
|
||||||
#acl = [ "pattern readwrite #" ];
|
# settings.allow_anonymous = true;
|
||||||
#omitPasswordAuth = true;
|
# acl = [ "pattern readwrite #" ];
|
||||||
|
# omitPasswordAuth = true;
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
# override umask to make permissions work out
|
# override umask to make permissions work out
|
||||||
@@ -76,19 +77,9 @@ in
|
|||||||
Group = "${service}";
|
Group = "${service}";
|
||||||
};
|
};
|
||||||
|
|
||||||
# # open firewall
|
# open firewall
|
||||||
networking.firewall.allowedTCPPorts = [ cfg.port ];
|
networking.firewall.allowedTCPPorts = [ cfg.port ];
|
||||||
|
|
||||||
# # internal reverse proxy entry
|
|
||||||
# services.nginx.virtualHosts."${cfg.url}" = {
|
|
||||||
# forceSSL = true;
|
|
||||||
# sslCertificate = sec."ssl_blakedheld_crt".path;
|
|
||||||
# sslCertificateKey = sec."ssl_blakedheld_key".path;
|
|
||||||
# locations."/" = {
|
|
||||||
# proxyPass = "http://127.0.0.1:${toString cfg.port}";
|
|
||||||
# };
|
|
||||||
# };
|
|
||||||
|
|
||||||
sops.secrets = {
|
sops.secrets = {
|
||||||
"${service}_hashed_passwd" = {
|
"${service}_hashed_passwd" = {
|
||||||
owner = "${service}";
|
owner = "${service}";
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ in
|
|||||||
};
|
};
|
||||||
url = lib.mkOption {
|
url = lib.mkOption {
|
||||||
type = lib.types.str;
|
type = lib.types.str;
|
||||||
default = "${service}.${homelab.base_domain}";
|
default = "z2m.${homelab.base_domain}";
|
||||||
description = "set domain for ${service}";
|
description = "set domain for ${service}";
|
||||||
};
|
};
|
||||||
data_dir = lib.mkOption {
|
data_dir = lib.mkOption {
|
||||||
@@ -111,6 +111,14 @@ in
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# add to glance
|
||||||
|
modules.services.glance.links.services = [{
|
||||||
|
title = service;
|
||||||
|
url = "https://${cfg.url}";
|
||||||
|
error-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||||
|
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||||
|
icon = "di:${service}"; }];
|
||||||
|
|
||||||
# add to backups
|
# add to backups
|
||||||
modules.system.backups.baks = {
|
modules.system.backups.baks = {
|
||||||
${service} = { paths = [ cfg.data_dir ]; };
|
${service} = { paths = [ cfg.data_dir ]; };
|
||||||
|
|||||||
@@ -99,6 +99,14 @@ in
|
|||||||
# };
|
# };
|
||||||
# };
|
# };
|
||||||
|
|
||||||
|
# add to glance
|
||||||
|
modules.services.glance.links.system = [{
|
||||||
|
title = service;
|
||||||
|
url = "https://${cfg.url}";
|
||||||
|
error-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||||
|
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||||
|
icon = "di:${service}"; }];
|
||||||
|
|
||||||
# add to backups
|
# add to backups
|
||||||
modules.system.backups.paths = lib.mkIf cfg.backup [ cfg.data_dir ];
|
modules.system.backups.paths = lib.mkIf cfg.backup [ cfg.data_dir ];
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -110,6 +110,14 @@ in
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# add to glance
|
||||||
|
modules.services.glance.links.services = [{
|
||||||
|
title = service;
|
||||||
|
url = "https://${homelab.base_domain}";
|
||||||
|
error-url = "http://${cfg.url}:${toString cfg.port}";
|
||||||
|
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||||
|
icon = "di:${service}"; }];
|
||||||
|
|
||||||
# add to backups
|
# add to backups
|
||||||
modules.system.backups.baks = {
|
modules.system.backups.baks = {
|
||||||
${service} = { paths = [ cfg.data_dir ]; };
|
${service} = { paths = [ cfg.data_dir ]; };
|
||||||
|
|||||||
Reference in New Issue
Block a user