homelab/nixos/hosts/traefik/configuration/static.nix
plasmagoat a90630ecb6
All checks were successful
Hello World / test (push) Successful in 12s
dump
2025-07-05 11:12:20 +02:00

63 lines
1.1 KiB
Nix

{
entryPoints = {
web = {
address = ":80";
asDefault = true;
allowACMEByPass = true;
http.redirections.entrypoint = {
priority = 10;
to = "websecure";
scheme = "https";
};
};
websecure = {
address = ":443";
http.tls.certResolver = "letsencrypt";
};
metrics = {
address = ":8082";
};
};
providers.file.watch = true;
api = {
dashboard = true;
insecure = true;
};
certificatesResolvers = {
letsencrypt = {
acme = {
email = "david.mikael@proton.me";
storage = "/var/lib/traefik/acme.json";
# httpChallenge = {
# entryPoint = "web";
# };
dnsChallenge = {
provider = "cloudflare";
delayBeforeCheck = 10;
resolvers = ["1.1.1.1:53" "8.8.8.8:53"];
};
};
};
};
metrics = {
prometheus = {
entryPoint = "metrics";
};
};
log = {
level = "DEBUG";
filePath = "/var/log/traefik/traefik.log";
};
accessLog = {
format = "json";
filePath = "/var/log/traefik/access.log";
};
}