ansible-role-traefik/templates/conf.d/10-api.toml

20 lines
455 B
TOML
Raw Normal View History

2020-11-27 12:39:51 +01:00
[http.middlewares.apiAuth.basicAuth]
users = [
"test:$apr1$H6uskkkW$IgXLP6ewTrSuBkTrqE8wj/",
]
[http.routers.my-api-redir]
2020-11-27 12:52:52 +01:00
rule = "{{ traefik_api_rule }}"
2020-11-27 12:39:51 +01:00
entryPoints = ["web"]
middlewares = ["httpsRedirect"]
service = "api@internal"
[http.routers.my-api]
2020-11-27 12:52:52 +01:00
rule = "{{ traefik_api_rule }}"
2020-11-27 12:39:51 +01:00
entryPoints = ["websecure"]
middlewares = ["apiAuth"]
service = "api@internal"
[http.routers.my-api.tls]
certResolver = "my-resolver"