-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yaml
40 lines (35 loc) · 1001 Bytes
/
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
version: '3.1'
services:
reverse-proxy:
# The official v2.0 Traefik docker image
image: traefik:v2.0
# Enables the web UI and tells Traefik to listen to docker
command: --api.insecure=true --providers.docker
ports:
# The HTTP port
- "80:80"
# The Web UI (enabled by --api.insecure=true)
- "8080:8080"
volumes:
# So that Traefik can listen to the Docker events
- /var/run/docker.sock:/var/run/docker.sock
mongo:
image: mongo
volumes:
- /data/mongodb/db:/data/db
userbe:
build:
context: backend/userbe
dockerfile: Dockerfile
environment:
DATABASE_URI: mongodb://mongo:27017/u4t
labels:
- "traefik.http.routers.userbe.rule=PathPrefix(`/api/users`)"
adminbe:
build:
context: backend/adminbe
dockerfile: Dockerfile
environment:
DATABASE_URI: mongodb://mongo:27017/u4t
labels:
- "traefik.http.routers.adminbe.rule=PathPrefix(`/api/admin`)"