-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
101 lines (93 loc) · 2.47 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
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
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
version: '3'
services:
rabbitmq:
image: rabbitmq:3.7-management
container_name: rabbitmq
hostname: rabbitmq
ports:
- 7000:15672
- 7001:5672
environment:
- RABBITMQ_DEFAULT_USER=${RABBITMQ_USER}
- RABBITMQ_DEFAULT_PASS=${RABBITMQ_PASSWORD}
transactions-db:
image: postgres
container_name: transactions-db
environment:
POSTGRES_PASSWORD: ${TRANSACTIONS_DB_PASSWORD}
POSTGRES_USER: ${TRANSACTIONS_DB_USER}
POSTGRES_DB: ${TRANSACTIONS_DB}
ports:
- 5442:5432
transactions-service:
depends_on:
- transactions-db
- rabbitmq
links:
- transactions-db
container_name: transactions-service
build: ./services/transactions
ports:
- 3010:3000
volumes:
- ./services/transactions/src:/usr/src/app/src
working_dir: /usr/src/app/src
environment:
POSTGRES_PASSWORD: ${TRANSACTIONS_DB_PASSWORD}
POSTGRES_USER: ${TRANSACTIONS_DB_USER}
POSTGRES_DB: ${TRANSACTIONS_DB}
RABBITMQ_USER: ${RABBITMQ_USER}
RABBITMQ_PASSWORD: ${RABBITMQ_PASSWORD}
command: nodemon app.js
recommendations-db:
container_name: recommendations-db
image: mongo
restart: always
ports:
- 27017:27017
recommendations-service:
depends_on:
- recommendations-db
- rabbitmq
links:
- recommendations-db
container_name: recommendations-service
build: ./services/recommendations
ports:
- 3000:3000
volumes:
- ./services/recommendations/src:/usr/src/app/src
working_dir: /usr/src/app/src
environment:
RABBITMQ_USER: ${RABBITMQ_USER}
RABBITMQ_PASSWORD: ${RABBITMQ_PASSWORD}
command: nodemon app.js
generator-db:
image: postgres
container_name: generator-db
environment:
POSTGRES_PASSWORD: ${GENERATOR_DB_PASSWORD}
POSTGRES_USER: ${GENERATOR_DB_USER}
POSTGRES_DB: ${GENERATOR_DB}
ports:
- 5433:5432
generator-service:
depends_on:
- generator-db
- rabbitmq
links:
- generator-db
container_name: generator-service
build: ./services/generator
ports:
- 5000:5000
volumes:
- ./services/generator/src:/usr/src/app/src
environment:
POSTGRES_PASSWORD: ${GENERATOR_DB_PASSWORD}
POSTGRES_USER: ${GENERATOR_DB_USER}
POSTGRES_DB: ${GENERATOR_DB}
RABBITMQ_USER: ${RABBITMQ_USER}
RABBITMQ_PASSWORD: ${RABBITMQ_PASSWORD}
working_dir: /usr/src/app/src
command: nodemon app.py