wip: wildcard domain
Some checks failed
continuous-integration/drone/push Build is failing

This commit is contained in:
knoflook 2025-01-30 11:31:03 +01:00
parent 1cc375cf19
commit 7fd09f34a5
2 changed files with 5 additions and 1 deletions

View File

@ -7,6 +7,9 @@ COMPOSE_FILE="compose.yml"
## Domain aliases
#EXTRA_DOMAINS=', `www.baserow.example.com`'
## Automatically use subdomains under following domain (anything.example.com)
#WILDCARD_DOMAIN='example.com'
LETS_ENCRYPT_ENV=production
# COMPOSE_FILE="$COMPOSE_FILE:compose.email.yml"

View File

@ -11,6 +11,7 @@ services:
- SECRET_KEY_FILE=/run/secrets/secret_key
- BASEROW_JWT_SIGNING_KEY_FILE=/run/secrets/baserow_jwt_signing_key
- BASEROW_CADDY_ADDRESSES=:80
- BASEROW_BUILDER_DOMAINS=${WILDCARD_DOMAIN}
secrets:
- secret_key
- baserow_jwt_signing_key
@ -20,7 +21,7 @@ services:
labels:
- "traefik.enable=true"
- "traefik.http.services.${STACK_NAME}.loadbalancer.server.port=80"
- "traefik.http.routers.${STACK_NAME}.rule=Host(`${DOMAIN}`${EXTRA_DOMAINS})"
- "traefik.http.routers.${STACK_NAME}.rule=Host(`${DOMAIN}`${EXTRA_DOMAINS}) || HostRegexp(`{subdomain:\\w+}.${WILDCARD_DOMAIN}`)"
- "traefik.http.routers.${STACK_NAME}.entrypoints=web-secure"
- "traefik.http.routers.${STACK_NAME}.tls.certresolver=${LETS_ENCRYPT_ENV}"
## Redirect from EXTRA_DOMAINS to DOMAIN