-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
37 lines (37 loc) · 1.03 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
#docker-compose up -d
version: '3'
services:
proxy:
image: traefik
command: --api.insecure=true --providers.docker
ports:
- "8080:8080"
- "8081:80"
volumes:
- /var/run/docker.sock:/var/run/docker.sock
app-authors-service:
image: jaimesalvador/app-authors
deploy:
replicas: 3
expose:
- 8080
labels:
- "traefik.http.routers.authors.rule=PathPrefix(`/app-authors`)"
- "traefik.http.middlewares.authors.stripprefix.prefixes=/app-authors"
- "traefik.http.routers.authors.middlewares=authors"
#ports:
# - "8080:8080" #HOST:CONTENEDOR
app-books-service:
image: jaimesalvador/app-books
environment:
APP_AUTHORS_URL: http://proxy/app-authors
deploy:
replicas: 2
expose:
- 8080
labels:
- "traefik.http.routers.books.rule=PathPrefix(`/app-books`)"
- "traefik.http.middlewares.books.stripprefix.prefixes=/app-books"
- "traefik.http.routers.books.middlewares=books"
#ports:
# - "9090:8080" #HOST:CONTENEDOR