glance: Init module

This commit is contained in:
SebastianStork 2026-03-09 21:37:16 +01:00
parent fd5acfbcf6
commit 3abf299cd6
Signed by: SebastianStork
SSH key fingerprint: SHA256:tRrGdjYOwgHxpSc/wTOZQZEjxcb15P0tyXRsbAfd+2Q
2 changed files with 35 additions and 0 deletions

View file

@ -72,6 +72,11 @@
domain = "status.${config.custom.networking.overlay.domain}";
generateDefaultEndpoints = true;
};
glance = {
enable = true;
domain = "home.${config.custom.networking.overlay.domain}";
};
};
};
}

View file

@ -0,0 +1,30 @@
{ config, lib, ... }:
let
cfg = config.custom.web-services.glance;
in
{
options.custom.web-services.glance = {
enable = lib.mkEnableOption "";
domain = lib.mkOption {
type = lib.types.nonEmptyStr;
default = "";
};
port = lib.mkOption {
type = lib.types.port;
default = 63958;
};
};
config = lib.mkIf cfg.enable {
services.glance = {
enable = true;
settings = {
inherit (cfg) port;
#pages
};
};
custom.services.caddy.virtualHosts.${cfg.domain}.port = cfg.port;
};
}