forked from spylkkanen/kubernetes-microservices
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
55 lines (51 loc) · 1.24 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
52
53
54
55
version: '3'
services:
frontend:
image: ${DOCKER_REG}microservice-example-1/frontend${DOCKER_TAG}
build:
context: .
dockerfile: frontend/Dockerfile
args:
build_config: production
ports:
- 9000:3000
environment:
- PORT=3000
- SERVICE_API1_ENDPOINT=http://localhost:9010/api
networks:
- microservice-example-network
backend-api1:
image: ${DOCKER_REG}microservice-example-1/backend-api1${DOCKER_TAG}
build:
context: .
dockerfile: backend-api1/Dockerfile
args:
build_info: Built from Docker compose
ports:
- 9010:3010
depends_on:
- frontend
environment:
- PORT=3010
- SERVICE_API2_ENDPOINT=http://backend-api2:3020/api
networks:
- microservice-example-network
backend-api2:
image: ${DOCKER_REG}microservice-example-1/backend-api2${DOCKER_TAG}
build:
context: .
dockerfile: backend-api2/Dockerfile
args:
build_info: Built from Docker compose
#ports:
# - 9020:3020
expose:
- 3020
depends_on:
- backend-api1
environment:
- PORT=3020
networks:
- microservice-example-network
networks:
microservice-example-network: