-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
215 lines (184 loc) · 4.5 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
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
version: '3.8'
services:
zookeeper:
image: 'bitnami/zookeeper:latest'
container_name: zookeeper
restart: always
ports:
- "2181:2181"
environment:
- ALLOW_ANONYMOUS_LOGIN=yes
kafka:
image: 'bitnami/kafka:latest'
container_name: kafka
ports:
- "9092:9092"
restart: always
depends_on:
- zookeeper
environment:
- KAFKA_BROKER_ID=1
- KAFKA_CFG_LISTENERS=LISTENER_BRNA://localhost:9092,LISTENER_BRNOZ://kafka:29092
- KAFKA_CFG_LISTENER_SECURITY_PROTOCOL_MAP=LISTENER_BRNA:PLAINTEXT,LISTENER_BRNOZ:PLAINTEXT
- KAFKA_CFG_ADVERTISED_LISTENERS=LISTENER_BRNA://localhost:9092,LISTENER_BRNOZ://kafka:29092
- KAFKA_CFG_INTER_BROKER_LISTENER_NAME=LISTENER_BRNOZ
- KAFKA_CFG_ZOOKEEPER_CONNECT=zookeeper:2181
- ALLOW_PLAINTEXT_LISTENER=yes
configserver:
build: ./configServer
container_name: configserver
image: config-server-image
restart: always
ports:
- "8889:8888"
volumes:
- ./configServer:/app
environment:
- SPRING_CLOUD_CONFIG_SERVER_GIT_URI=https://github.com/bernaozgen/configServer
discoveryserver:
build: ./discovery-server
container_name: discoveryserver
image: discovery-server-image
restart: always
ports:
- "9001:9001"
volumes:
- ./discovery-server:/app
depends_on:
- configserver
apigateway:
build: ./apigateway
container_name: apigateway
image: bernaozgen/api-gateway-image
restart: always
ports:
- "9011:9011"
volumes:
- ./apigateway:/app
depends_on:
- discoveryserver
- configserver
environment:
- SPRING_PROFILES_ACTIVE=docker
rentacarinventorydb:
container_name: rentacarinventorydb
image: postgres
restart: always
ports:
- "5437:5432"
environment:
- POSTGRES_USERS=admin
- POSTGRES_PASSWORD=123456
volumes:
- "./pg_data:/var/lib/postgresql/data"
inventory-services:
build: ./inventoryService
container_name: inventory-service
image: inventory-service
restart: always
volumes:
- ./inventoryService:/app
depends_on:
- rentacarinventorydb
- discoveryserver
- kafka
- configserver
environment:
- SPRING_PROFILES_ACTIVE=docker
rentalcarmongodb:
container_name: rentalcarmongodb
image: mongo
restart: always
ports:
- "27017:27017"
volumes:
- "/data/db/"
filterService:
build: ./filterService
container_name: filterService
image: filter-service
restart: always
volumes:
- ./filterService:/app
depends_on:
- configserver
- discoveryserver
- kafka
- rentalcarmongodb
environment:
- SPRING_PROFILES_ACTIVE=docker
rentacarrentaldb:
container_name: rentacarrentaldb
image: postgres
restart: always
ports:
- "5436:5432"
environment:
- POSTGRES_USER=admin
- POSTGRES_PASSWORD=123456
volumes:
- "./pg_data:/var/lib/postgresql/data"
rental-service:
build: ./rental-service
container_name: rentalService
image: rental-service
restart: always
volumes:
- ./rental-service:/app
depends_on:
- rentacarrentaldb
- discoveryserver
- kafka
- configserver
environment:
- SPRING_PROFILES_ACTIVE=docker
rentacarpaymentdb:
container_name: rentacarpaymentdb
image: postgres
restart: always
ports:
- "5438:5432"
environment:
- POSTGRES_USER=admin
- POSTGRES_PASSWORD=12345
volumes:
- "./pg_data:/var/lib/postgresql/data"
paymentService:
build: ./paymentService
container_name: paymentService
image: payment-service
restart: always
volumes:
- ./paymentService:/app
depends_on:
- rentacarpaymentdb
- discoveryserver
- kafka
- configserver
environment:
- SPRING_PROFILES_ACTIVE=docker
rentacarinvoicedb:
container_name: rentacarinvoicedb
image: postgres
restart: always
ports:
- "5439:5432"
environment:
- POSTGRES_USER=admin
- POSTGRES_PASSWORD=12345
volumes:
- "./pg_data:/var/lib/postgresql/data"
invoiceService:
build: ./invoiceService
container_name: invoiceService
image: invoice-service
restart: always
volumes:
- ./invoiceService:/app
depends_on:
- rentacarinvoicedb
- discoveryserver
- kafka
- configserver
environment:
- SPRING_PROFILES_ACTIVE=docker