+ portUtils +metabase

This commit is contained in:
m3tam3re
2025-09-29 15:44:25 +02:00
parent 7cf5f7d06f
commit c11847206f
18 changed files with 317 additions and 109 deletions

View File

@@ -1,33 +1,39 @@
{config, ...}:{
services = {
zammad = {
enable = true;
openPorts = false;
port = 3034;
secretKeyBaseFile = "${config.age.secrets.zammad-secret.path}";
database = {
createLocally = false;
port = 5432;
host = "127.0.0.1";
passwordFile = "${config.age.secrets.zammad-pw.path}";
};
{
config,
lib,
...
}: let
serviceName = "zammad";
portUtils = import ../../../lib/port-utils.nix {inherit lib;};
servicePort = portUtils.getPort serviceName "AZ-CLD-1";
in {
services.${serviceName} = {
enable = true;
openPorts = false;
port = servicePort;
secretKeyBaseFile = config.age.secrets.zammad-secret.path;
database = {
createLocally = false;
port = 5432;
host = "127.0.0.1";
passwordFile = config.age.secrets.zammad-pw.path;
};
};
# Traefik configuration specific to littlelink
# Traefik configuration
services.traefik.dynamicConfigOptions.http = {
services.zammad.loadBalancer.servers = [
services.${serviceName}.loadBalancer.servers = [
{
url = "http://localhost:3034/";
url = "http://localhost:${toString servicePort}/";
}
];
routers.zammad = {
routers.${serviceName} = {
rule = "Host(`help.az-gruppe.com`)";
tls = {
certResolver = "ionos";
};
service = "zammad";
service = serviceName;
entrypoints = "websecure";
};
};