tried but still failing redirect

This commit is contained in:
Roxie Gibson 2021-05-09 22:40:49 +01:00
parent b655514b86
commit d566060e5c
Signed by: roxxers
GPG Key ID: 5D0140EDEE123F4D
2 changed files with 25 additions and 7 deletions

View File

@ -1,6 +1,10 @@
TYPE=mastodon
DOMAIN=mastodon.swarm-test.autonomic.zone
# Enables WEB_DOMAIN if set (FOR FUTURE USE)
# USER_DOMAIN=
## Domain aliases
#EXTRA_DOMAINS=', `www.mastodon.example.com`'
LETS_ENCRYPT_ENV=production
@ -13,8 +17,18 @@ LETS_ENCRYPT_ENV=production
# Federation
# ----------
# DO NOT CHANGE DOMAIN VARIABLES AFTER DEPLOYMENT! WILL BREAK FEDERATION!!
# if [ -z "$USER_DOMAIN" ]
# then
# LOCAL_DOMAIN=$DOMAIN
# else
# LOCAL_DOMAIN=$USER_DOMAIN
# WEB_DOMAIN=$DOMAIN
# fi
LOCAL_DOMAIN=$DOMAIN
#WEB_DOMAIN=
#WEB_DOMAIN=$DOMAIN
#ALTERNATE_DOMAINS=$EXTRA_DOMAINS
AUTHORIZED_FETCH=false
LIMITED_FEDERATION_MODE=false
@ -56,8 +70,8 @@ ES_ENABLED=false
# StatsD (CURRENTLY NOT SUPPORTED)
# -------------------------------
STATSD_ADDR
STATSD_NAMESPACE
# STATSD_ADDR
# STATSD_NAMESPACE
# Secrets
# =======

View File

@ -60,11 +60,15 @@ services:
- "traefik.http.routers.${STACK_NAME}_web.rule=Host(`${DOMAIN}`)"
- "traefik.http.routers.${STACK_NAME}_web.entrypoints=web-secure"
- "traefik.http.routers.${STACK_NAME}_web.tls.certresolver=${LETS_ENCRYPT_ENV}"
# WEB_DOMAIN redirect
#- "traefik.http.routers.${STACK_NAME}_web.rule=(Host(`${DOMAIN}`) || (Host(`${LOCAL_DOMAIN}`) && Path(`/.well-known/webfinger`)))"
# - "traefik.http.middlewares.mastodon-webfinger.redirectregex.regex=^https?://${LOCAL_DOMAIN}/.*" #^(http|https)://${LOCAL_DOMAIN}/.well-known/webfinger"
# # - "traefik.http.middlewares.mastodon-webfinger.redirectregex.permanent=true"
# - "traefik.http.middlewares.mastodon-webfinger.redirectregex.replacement=https://${WEB_DOMAIN}/.well-known/webfinger"
# - "traefik.http.routers.${STACK_NAME}_hack.rule=(Host(`${LOCAL_DOMAIN}`) && Path(`/.well-known/`))"
# - "traefik.http.routers.${STACK_NAME}_hack.entrypoints=websecure"
# - "traefik.http.routers.${STACK_NAME}_hack.middlewares=mastodon-webfinger@docker"
## Redirect from EXTRA_DOMAINS to DOMAIN
#- "traefik.http.routers.${STACK_NAME}.middlewares=${STACK_NAME}-redirect"
#- "traefik.http.middlewares.${STACK_NAME}-redirect.headers.SSLForceHost=true"
#- "traefik.http.middlewares.${STACK_NAME}-redirect.headers.SSLHost=${DOMAIN}"
depends_on:
- db
- redis