-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yaml
86 lines (81 loc) · 3.21 KB
/
docker-compose.yaml
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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
services:
traefik:
# The official v2 Traefik docker image
image: traefik:v2.6
# Enables the web UI and tells Traefik to listen to docker
command:
- "--log.level=DEBUG"
- "--api.insecure=true"
- "--providers.docker=true"
- "--providers.docker.exposedbydefault=false"
# - "--providers.docker.exposedbydefault=false"
- "--entrypoints.web.address=:80"
# - "--entrypoints.websecure.address=:4443"
# - "--certificatesresolvers.myresolver.acme.tlschallenge=true"
# - "--certificatesresolvers.myresolver.acme.caserver=https://acme-staging-v02.api.letsencrypt.org/directory"
# - "--certificatesresolvers.myresolver.acme.email=tobias.hess@uni-ulm.com"
# - "--certificatesresolvers.myresolver.acme.storage=/letsencrypt/acme.json"
labels:
- "traefik.http.routers.traefik.service=api@internal"
# - traefik.http.routers.traefik.rule=HostRegexp(`localhost`)
# - traefik.http.routers.to-https.rule=HostRegexp(`localhost`)
# - traefik.http.routers.to-https.rule=HostRegexp(`{host:.+}`)
# - traefik.http.routers.to-https.entrypoints=http
# - traefik.http.routers.to-https.middlewares=to-https
ports:
- "3000:80"
# - "4443:4443"
# The Web UI (enabled by --api.insecure=true)
- "8080:8080"
volumes:
# So that Traefik can listen to the Docker events
# - "./letsencrypt:/letsencrypt"
- "/run/user/1000/docker.sock:/var/run/docker.sock:ro"
networks:
- vdev
editor:
networks:
- vdev
build: .
command: npm run dev -- --host 0.0.0.0
# ports:
# - 3001:3000
restart: unless-stopped
labels:
- "traefik.enable=true"
- "traefik.http.routers.editor.rule=Host(`editor.localhost`)"
- "traefik.http.routers.editor.entrypoints=web"
- "traefik.http.services.editor.loadbalancer.server.port=3000"
# - "traefik.http.routers.frontend.entrypoints=websecure"
# - "traefik.http.routers.frontend.tls.certresolver=myresolver"
# - "traefik.http.middlewares.redirector.redirectscheme.scheme=https"
# - "traefik.http.middlewares.redirector.redirectscheme.permanent=true"
peerjs:
image: peerjs/peerjs-server
restart: unless-stopped
networks:
- vdev
labels:
- "traefik.enable=true"
- "traefik.http.routers.peerjs.rule=Host(`peerjs.localhost`)"
- "traefik.http.routers.peerjs.entrypoints=web"
- "traefik.http.services.peerjs.loadbalancer.server.port=9000"
# - "traefik.http.routers.peerjs.entrypoints=websecure"
# - "traefik.http.routers.peerjs.tls.certresolver=myresolver"
# - "traefik.http.middlewares.redirector.redirectscheme.scheme=https"
# - "traefik.http.middlewares.redirector.redirectscheme.permanent=true"
backend:
build: backend
command: python3 -m flask run --host=0.0.0.0
networks:
- vdev
labels:
- "traefik.enable=true"
- "traefik.http.routers.backend.rule=Host(`backend.localhost`)"
- "traefik.http.routers.backend.entrypoints=web"
# - "traefik.http.routers.backend.tls.certresolver=myresolver"
- "traefik.http.services.backend.loadbalancer.server.port=5000"
networks:
vdev:
name: vdev
driver: bridge