docker-server/traefik/config/security.yaml

36 lines
880 B
YAML

# This file contains services for security and authorization
http:
services:
http-catchall:
# A dummy service for the http-catchall rule
loadBalancer:
servers:
- url: http://dummy-url
routers:
http-catchall:
# Catch all requests to the http entrypoint and redirect them to https
service: http-catchall
rule: hostregexp(`{host:.+}`)
entrypoint: web
middlewares:
- redir
middlewares:
redir:
# Redirect to https
redirectScheme:
scheme: https
permanent: true
auth:
# Go through authelia for authorization
forwardAuth:
address: http://authelia:9091/api/verify?rd=https://auth.{{ env "PRIVATE_DOMAIN" }}/
trustForwardHeader: true
authResponseHeaders:
- X-Forwarded-User
tls:
insecureSkipVerify: true