-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
107 lines (98 loc) · 2.87 KB
/
docker-compose.yml
File metadata and controls
107 lines (98 loc) · 2.87 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
version: '3.9'
services:
postgres:
image: postgres:16-alpine
restart: always
container_name: postgres
shm_size: 128mb
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: postgres
ports:
- "5432:5432"
volumes:
- ./pgdata:/var/lib/postgresql/data
# - ./init_db.sql:/docker-entrypoint-initdb.d/init_db.sql
# - ./db_dumps:/docker-entrypoint-initdb.d/db_dumps
redis:
image: redis:7-alpine
container_name: redis
ports:
- "6379:6379"
kafka:
image: confluentinc/cp-kafka:7.6.0
container_name: kafka
ports:
- "9092:9092"
environment:
KAFKA_NODE_ID: 1
KAFKA_LISTENERS: PLAINTEXT://0.0.0.0:9092,CONTROLLER://0.0.0.0:9093
KAFKA_ADVERTISED_LISTENERS: PLAINTEXT://kafka:9092
KAFKA_CONTROLLER_LISTENER_NAMES: CONTROLLER
KAFKA_CONTROLLER_QUORUM_VOTERS: 1@kafka:9093
KAFKA_PROCESS_ROLES: broker,controller
CLUSTER_ID: "nWbzJEOwTv-yNbACv9y06A"
volumes:
- ./kafka-data:/opt/kafka/logs
users-service:
build:
context: .
dockerfile: src/Locator.Users/Users.Web/Dockerfile
container_name: users-service
ports:
- "5000:8080"
environment:
- ConnectionStrings__UsersDb=Host=postgres;Port=5432;Database=users_db;Username=postgres;Password=postgres
- ConnectionStrings__FakeHeadHunterDb=Host=postgres;Port=5432;Database=head_hunter_db;Username=postgres;Password=postgres
- Redis__Connection=redis:6379
depends_on:
- postgres
- redis
ratings-service:
build:
context: .
dockerfile: src/Locator.Ratings/Ratings.Web/Dockerfile
container_name: ratings-service
ports:
- "5001:8080"
environment:
- ConnectionStrings__RatingsDb=Host=postgres;Port=5432;Database=ratings_db;Username=postgres;Password=postgres
- Kafka__BootstrapServers=kafka:9092
depends_on:
- postgres
- kafka
vacancies-service:
build:
context: .
dockerfile: src/Locator.Vacancies/Vacancies.Web/Dockerfile
container_name: vacancies-service
ports:
- "5002:8080"
environment:
- ConnectionStrings__VacanciesDb=Host=postgres;Port=5432;Database=vacancies_db;Username=postgres;Password=postgres
- ConnectionStrings__FakeHeadHunterDb=Host=postgres;Port=5432;Database=head_hunter_db;Username=postgres;Password=postgres
- Kafka__BootstrapServers=kafka:9092
depends_on:
- postgres
- kafka
api-gateway:
build:
context: .
dockerfile: src/Locator.ApiGateway/ApiGateway.Web/Dockerfile
container_name: api-gateway
ports:
- "5003:8080"
depends_on:
- users-service
- ratings-service
- vacancies-service
client:
build:
context: ./client
dockerfile: Dockerfile
container_name: client
ports:
- "5173:80"
depends_on:
- api-gateway