wildcard-auth.yml37 lines · main
1# Wildcard hosted auth: https://<projectId>.auth.briven.tech → API
2# Requires Traefik certificatesResolvers.cloudflare (DNS-01) + CF_DNS_API_TOKEN
3# with Zone:DNS:Edit on briven.tech. Until the token can see zone briven.tech,
4# magic-link emails use api.briven.tech (valid HTTP-01 cert) via hostedAuthBaseUrl.
5#
6# Deploy:
7# scp infra/traefik/wildcard-auth.yml root@host:/etc/dokploy/traefik/dynamic/wildcard-auth.yml
8# # ensure traefik.yml has cloudflare resolver + container has CF_DNS_API_TOKEN
9
10http:
11 routers:
12 briven-auth-http:
13 rule: "HostRegexp(`^.+\\.auth\\.briven\\.tech$`)"
14 entryPoints:
15 - web
16 middlewares:
17 - redirect-to-https
18 service: briven-auth-api
19
20 briven-auth-https:
21 rule: "HostRegexp(`^.+\\.auth\\.briven\\.tech$`)"
22 entryPoints:
23 - websecure
24 service: briven-auth-api
25 tls:
26 certResolver: cloudflare
27 domains:
28 - main: "auth.briven.tech"
29 sans:
30 - "*.auth.briven.tech"
31
32 services:
33 briven-auth-api:
34 loadBalancer:
35 servers:
36 - url: "http://briven-brivenfrance-uilsk6-api-1:3001"
37 passHostHeader: true