Configuration cleanup
This commit is contained in:
29
traefik/config/network.yaml
Normal file
29
traefik/config/network.yaml
Normal file
@@ -0,0 +1,29 @@
|
||||
# This file contains routing rules for netwok services that are not running on the same host as traefik
|
||||
|
||||
http:
|
||||
services:
|
||||
pfsense:
|
||||
loadBalancer:
|
||||
servers:
|
||||
- url: http://192.168.0.1:80
|
||||
proxmox:
|
||||
loadBalancer:
|
||||
servers:
|
||||
- url: http://192.168.0.10:8006
|
||||
|
||||
routers:
|
||||
pfsense:
|
||||
service: pfsense
|
||||
rule: Host(`pfsense.{{ env "PRIVATE_DOMAIN" }}`)
|
||||
middlewares:
|
||||
- auth
|
||||
tls:
|
||||
certResolver: le
|
||||
proxmox:
|
||||
service: proxmox
|
||||
rule: Host(`proxmox.{{ env "PRIVATE_DOMAIN" }}`)
|
||||
middlewares:
|
||||
- auth
|
||||
tls:
|
||||
certResolver: le
|
||||
|
||||
35
traefik/config/security.yaml
Normal file
35
traefik/config/security.yaml
Normal file
@@ -0,0 +1,35 @@
|
||||
# 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" }}/%23/
|
||||
trustForwardHeader: true
|
||||
authResponseHeaders:
|
||||
- X-Forwarded-User
|
||||
insecureSkipVerify: true
|
||||
|
||||
Reference in New Issue
Block a user