-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
51 lines (48 loc) · 1.71 KB
/
docker-compose.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
version: "3.8"
services:
webdav:
image: ghcr.io/vaggeliskls/webdav-server:latest
build:
context: .
dockerfile: Dockerfile
platform: linux/amd64
volumes:
- ./webdav-data:/var/lib/dav/data
networks:
- webdav-network
env_file:
- .env
labels:
- "traefik.enable=true"
- "traefik.http.routers.webdav.service=webdav"
# Register Middleware ====================================================
- "traefik.http.routers.webdav.middlewares=compresstraefik,ratelimit"
# =================================================================================
- "traefik.http.middlewares.compresstraefik.compress=true"
- "traefik.http.services.webdav.loadbalancer.server.port=8080"
- "traefik.http.services.webdav.loadbalancer.passhostheader=true"
## Use PathPrefix rule to catch all requests
- "traefik.http.routers.webdav.rule=PathPrefix(`/`)"
- "traefik.http.routers.webdav.entrypoints=web,websecure"
## Rate Limiting Middleware (Per IP) =====================================
- "traefik.http.middlewares.ratelimit.ratelimit.average=5"
- "traefik.http.middlewares.ratelimit.ratelimit.burst=6"
- "traefik.http.middlewares.ratelimit.ratelimit.sourcecriterion.ipstrategy.depth=1"
webdav-proxy:
image: traefik:v3.1
platform: linux/amd64
command:
- "--providers.docker=true"
- "--providers.docker.exposedbydefault=false"
- "--entrypoints.web.address=:80"
- "--entrypoints.websecure.address=:443"
ports:
- "80:80"
- "443:443"
volumes:
- /var/run/docker.sock:/var/run/docker.sock
networks:
- webdav-network
networks:
webdav-network:
driver: bridge