+ portUtils +metabase
This commit is contained in:
@@ -1,10 +1,14 @@
|
||||
{
|
||||
services.gitea = {
|
||||
{lib, ...}: let
|
||||
serviceName = "gitea";
|
||||
portUtils = import ../../../lib/port-utils.nix {inherit lib;};
|
||||
servicePort = portUtils.getPort serviceName "AZ-CLD-1";
|
||||
in {
|
||||
services.${serviceName} = {
|
||||
enable = true;
|
||||
settings = {
|
||||
server = {
|
||||
ROOT_URL = "https://git.az-gruppe.com";
|
||||
HTTP_PORT = 3030;
|
||||
HTTP_PORT = servicePort;
|
||||
};
|
||||
mailer.SENDMAIL_PATH = "/run/wrappers/bin/sendmail";
|
||||
service.DISABLE_REGISTRATION = true;
|
||||
@@ -17,20 +21,21 @@
|
||||
backupDir = "/var/backup/gitea";
|
||||
};
|
||||
};
|
||||
# Traefik configuration specific to gitea
|
||||
|
||||
# Traefik configuration
|
||||
services.traefik.dynamicConfigOptions.http = {
|
||||
services.gitea.loadBalancer.servers = [
|
||||
services.${serviceName}.loadBalancer.servers = [
|
||||
{
|
||||
url = "http://localhost:3030/";
|
||||
url = "http://localhost:${toString servicePort}/";
|
||||
}
|
||||
];
|
||||
|
||||
routers.gitea = {
|
||||
routers.${serviceName} = {
|
||||
rule = "Host(`git.az-gruppe.com`)";
|
||||
tls = {
|
||||
certResolver = "ionos";
|
||||
};
|
||||
service = "gitea";
|
||||
service = serviceName;
|
||||
entrypoints = "websecure";
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user