@@ -3,7 +3,7 @@ services:
33 socket-proxy :
44 # this image is used to expose the docker socket as read-only to traefik
55 # you can check https://github.com/11notes/docker-socket-proxy for all details
6- image : " 11notes/socket-proxy:2.1.2 "
6+ image : " 11notes/socket-proxy:2.1.3 "
77 read_only : true
88 user : " 0:108"
99 environment :
@@ -21,16 +21,12 @@ services:
2121 image : " 11notes/traefik:3.5.0"
2222 read_only : true
2323 labels :
24- # read Traefiks own labels
2524 - " traefik.enable=true"
2625
27- # example on how to secure the traefik dashboard and api
28- - " traefik.http.routers.dashboard.rule=Host(`${TRAEFIK_FQDN}`)"
29- - " traefik.http.routers.dashboard.service=api@internal"
30- - " traefik.http.routers.dashboard.middlewares=dashboard-auth"
31- - " traefik.http.routers.dashboard.entrypoints=https"
32- # admin / traefik, please change!
33- - " traefik.http.middlewares.dashboard-auth.basicauth.users=admin:$$2a$$12$$ktgZsFQZ0S1FeQbI1JjS9u36fAJMHDQaY6LNi9EkEp8sKtP5BK43C"
26+ # default errors middleware
27+ - " traefik.http.middlewares.default-errors.errors.status=402-599"
28+ - " traefik.http.middlewares.default-errors.errors.query=/{status}"
29+ - " traefik.http.middlewares.default-errors.errors.service=default-errors"
3430
3531 # default ratelimit
3632 - " traefik.http.middlewares.default-ratelimit.ratelimit.average=100"
@@ -43,6 +39,14 @@ services:
4339 # default allowlist
4440 - " traefik.http.middlewares.default-ipallowlist-RFC1918.ipallowlist.sourcerange=10.0.0.0/8,172.16.0.0/12,192.168.0.0/16"
4541
42+ # example on how to secure the traefik dashboard and api
43+ - " traefik.http.routers.dashboard.rule=Host(`${TRAEFIK_FQDN}`)"
44+ - " traefik.http.routers.dashboard.service=api@internal"
45+ - " traefik.http.routers.dashboard.middlewares=dashboard-auth"
46+ - " traefik.http.routers.dashboard.entrypoints=https"
47+ # admin / traefik, please change!
48+ - " traefik.http.middlewares.dashboard-auth.basicauth.users=admin:$$2a$$12$$ktgZsFQZ0S1FeQbI1JjS9u36fAJMHDQaY6LNi9EkEp8sKtP5BK43C"
49+
4650 # default catch-all router
4751 - " traefik.http.routers.default.rule=HostRegexp(`.+`)"
4852 - " traefik.http.routers.default.priority=1"
@@ -58,11 +62,6 @@ services:
5862 - " traefik.http.routers.default-http.middlewares=default-http"
5963 - " traefik.http.routers.default-http.service=default-http"
6064 - " traefik.http.services.default-http.loadbalancer.passhostheader=true"
61-
62- # default errors middleware
63- - " traefik.http.middlewares.default-errors.errors.status=402-599"
64- - " traefik.http.middlewares.default-errors.errors.query=/{status}"
65- - " traefik.http.middlewares.default-errors.errors.service=default-errors"
6665 environment :
6766 TZ : " Europe/Zurich"
6867 command :
@@ -95,10 +94,9 @@ services:
9594 - " 443:443/tcp"
9695 volumes :
9796 - " var:/traefik/var"
97+ - " plugins:/traefik/plugins"
9898 # access docker socket via proxy read-only
9999 - " socket-proxy.run:/var/run"
100- # plugins stored as volume because of read-only
101- - " plugins:/plugins-storage"
102100 networks :
103101 backend :
104102 frontend :
@@ -109,7 +107,7 @@ services:
109107
110108 errors :
111109 # this image can be used to display a simple error message since Traefik can’t serve content
112- image : " 11notes/traefik:3.5.0 "
110+ image : " 11notes/traefik:errors "
113111 read_only : true
114112 labels :
115113 - " traefik.enable=true"
0 commit comments