begin work on authentik again

This commit is contained in:
2026-01-27 17:42:00 -06:00
parent 89328fe7e7
commit d7875217bd
6 changed files with 217 additions and 40 deletions

View File

@@ -1,4 +1,12 @@
{ config, lib, pkgs, ... }: {
{ config, lib, pkgs, ... }: let
hostPort = 11434;
subdomain = "ollama";
name = "ollama";
in {
options.sysconfig.docker.ollama.enable = with lib; mkOption {
type = with types; bool;
@@ -13,11 +21,11 @@
networking.firewall.interfaces = {
"ve-traefik" = {
allowedTCPPorts = [ 11434 ];
allowedTCPPorts = [ hostPort ];
};
"ve-openwebui" = {
allowedTCPPorts = [ 11434 ];
allowedTCPPorts = [ hostPort ];
};
};
@@ -27,14 +35,14 @@
# unstable, waiting for 26.05
#pull = "newer";
hostname = "ollama.esotericbytes.com";
hostname = "${subdomain}.esotericbytes.com";
networks = [
"docker-main"
];
ports = [
"11434:11434"
"${builtins.toString hostPort}:11434"
];
volumes = [
@@ -42,12 +50,12 @@
];
labels = {
"traefik.http.routers.ollama.entrypoints" = "localsecure";
"traefik.http.routers.ollama.rule" = "Host(`ollama.esotericbytes.com`)";
"traefik.http.routers.ollama.service" = "ollama";
"traefik.http.routers.ollama.tls.certResolver" = "cloudflare";
"traefik.http.routers.${name}.entrypoints" = "localsecure";
"traefik.http.routers.${name}.rule" = "Host(`${subdomain}.esotericbytes.com`)";
"traefik.http.routers.${name}.service" = "${name}";
"traefik.http.routers.${name}.tls.certResolver" = "cloudflare";
"traefik.http.services.ollama.loadbalancer.server.url" = "http://192.168.100.10:11434";
"traefik.http.services.ollama.loadbalancer.server.url" = "http://192.168.100.10:${builtins.toString hostPort}";
};
extraOptions = lib.mkIf config.sysconfig.docker.nvidia [