traefik
This commit is contained in:
@@ -19,15 +19,28 @@ in {
|
|||||||
image = "traefik:${version}";
|
image = "traefik:${version}";
|
||||||
ip = containerCfg.ip;
|
ip = containerCfg.ip;
|
||||||
secret = name;
|
secret = name;
|
||||||
extraEnv = {
|
extraLabels = {
|
||||||
config.sops.secrets.INFOMANIAK_API_KEY.path
|
"traefik.http.routers.${subdomain}.priority" = "10";
|
||||||
|
"traefik.http.routers.${subdomain}.service" = "api@internal";
|
||||||
|
"traefik.http.routers.${subdomain}.middlewares" = "authentik";
|
||||||
};
|
};
|
||||||
overrides = {
|
overrides = {
|
||||||
cmd = [
|
cmd = [
|
||||||
"--api"
|
"--api"
|
||||||
"--providers.docker=true"
|
"--providers.docker=true"
|
||||||
|
"--global.checknewversion=false"
|
||||||
|
"--global.sendanonymoususage=false"
|
||||||
|
"--api.debug=false"
|
||||||
|
"--api.insecure=true"
|
||||||
|
"--api.dashboard=true"
|
||||||
|
"--core.defaultrulesyntax=v3"
|
||||||
|
"--providers.docker.exposedByDefault=false"
|
||||||
"--entrypoints.web.address=:80"
|
"--entrypoints.web.address=:80"
|
||||||
"--entrypoints.web-secure.address=:443"
|
"--entrypoints.web-secure.address=:443"
|
||||||
|
"--entrypoints.web.http.redirections.entrypoint.to=web-secure"
|
||||||
|
"--entrypoints.web.http.redirections.entrypoint.scheme=https"
|
||||||
|
"--entrypoints.web-secure.transport.respondingtimeouts.readtimeout=0s"
|
||||||
|
"--entrypoints.web-secure.proxyprotocol.trustedips=127.0.0.1/32,192.168.1.1/16,10.10.0.0/16"
|
||||||
];
|
];
|
||||||
ports = [ "443" "80" ];
|
ports = [ "443" "80" ];
|
||||||
volumes = [
|
volumes = [
|
||||||
|
|||||||
@@ -27,6 +27,11 @@
|
|||||||
mailServer = "infomaniak.ch";
|
mailServer = "infomaniak.ch";
|
||||||
|
|
||||||
containers = {
|
containers = {
|
||||||
|
|
||||||
|
traefik = {
|
||||||
|
enable = true;
|
||||||
|
subdomain = "traefik";
|
||||||
|
};
|
||||||
authentik = {
|
authentik = {
|
||||||
enable = true;
|
enable = true;
|
||||||
db = true;
|
db = true;
|
||||||
|
|||||||
Reference in New Issue
Block a user