-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yaml
44 lines (44 loc) · 1.19 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
version: "3"
services:
traefik:
image: traefik
command:
- "--api.insecure=true"
- "--providers.docker=true"
- "--entrypoints.web.address=:80"
ports:
- "80:80"
- "8080:8080"
volumes:
- "/var/run/docker.sock:/var/run/docker.sock:ro"
swagger:
image: boilerplate/swagger
build:
context: .
dockerfile: swagger/Dockerfile
ports:
- "8082:8080"
labels:
- traefik.http.routers.swagger.rule=Host(`swagger.localhost`)
- traefik.http.services.swagger.loadbalancer.server.port=8080
api:
image: boilerplate/api
build:
context: .
dockerfile: api/cmd/Dockerfile
ports:
- "8081:8081"
labels:
- traefik.http.routers.api.rule=Host(`localhost`) && PathPrefix(`/api`)
- traefik.http.middlewares.api-stripprefix.stripprefix.prefixes=/api
- traefik.http.middlewares.api-cors.headers.accesscontrolalloworiginlist=*
- traefik.http.routers.api.middlewares=api-stripprefix@docker,api-cors@docker
ui:
image: boilerplate/ui
build:
context: .
dockerfile: ui/Dockerfile
ports:
- "8083:80"
labels:
- traefik.http.routers.ui.rule=Host(`localhost`)