-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
141 lines (141 loc) · 2.75 KB
/
docker-compose.yml
File metadata and controls
141 lines (141 loc) · 2.75 KB
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
version: '2'
networks:
bridge:
driver: bridge
services:
applications:
build:
context: ./applications
container_name: applications
ports:
- "8084:8080"
environment:
- EXPENSES_HOST=expenses
networks:
- bridge
calculations:
build:
context: ./calculations
container_name: calculations
ports:
- "8085:8080"
networks:
- bridge
loans:
build:
context: ./loans
container_name: loans
depends_on:
- db
- clients
- applications
- calculations
ports:
- "8083:8080"
environment:
- DB_USER=test
- DB_PASSWORD=test
- DB_HOST=database
- CLIENTS_HOST=clients
- APPLICATIONS_HOST=applications
- CALCULATIONS_HOST=calculations
networks:
- bridge
expenses:
build:
context: ./expenses
container_name: expenses
depends_on:
- db
- clients
ports:
- "8082:8080"
environment:
- DB_USER=test
- DB_PASSWORD=test
- DB_HOST=database
- DB_PORT=5432
- DB_NAME=test
- CLIENTS_HOST=clients
- CLIENTS_PORT=8080
- CLIENTS_VERSION=v1
networks:
- bridge
interests:
build:
context: ./interests
container_name: interests
depends_on:
- db
- clients
ports:
- "8086:8080"
environment:
- DB_USER=test
- DB_PASSWORD=test
- DB_HOST=database
- DB_PORT=5432
- DB_NAME=test
- CLIENTS_HOST=clients
- CLIENTS_PORT=8080
- CLIENTS_VERSION=v1
networks:
- bridge
currency:
build:
context: ./currency
container_name: currency
depends_on:
- db
ports:
- "8081:8080"
environment:
- DB_USER=test
- DB_PASSWORD=test
- DB_HOST=database
- DB_PORT=5432
- DB_NAME=test
networks:
- bridge
clients:
build:
context: ./clients
container_name: clients
depends_on:
- db
ports:
- "8080:8080"
environment:
- DB_USER=test
- DB_PASSWORD=test
- DB_HOST=database
- DB_PORT=5432
- DB_NAME=test
networks:
- bridge
migrate:
image: amacneil/dbmate
container_name: migrate
depends_on:
- db
volumes:
- ./sql:/db/migrations
environment:
- DATABASE_URL=postgresql://test:test@database:5432/test?sslmode=disable
networks:
- bridge
db:
image: postgres
container_name: database
volumes:
- ./postgres-data:/var/lib/postgresql/data
ports:
- "6432:5432"
environment:
- POSTGRES_ROOT_PASSWORD=test
- POSTGRES_PASSWORD=test
- POSTGRES_USER=test
- POSTGRES_DB=test
- POSTGRES_INITDB_ARGS="--encoding=UTF8"
networks:
- bridge