-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
88 lines (82 loc) · 1.79 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
version: "3.8"
services:
backend:
build: ./trading-system-go
ports:
- "8000:8000"
env_file: .env
volumes:
- ./trading-system-go:/usr/src/app
command: air
depends_on:
- db
- kafka
db:
image: postgres:alpine
restart: always
environment:
- POSTGRES_NAME=${DB_NAME}
- POSTGRES_USER=${DB_USER}
- POSTGRES_PASSWORD=${DB_PASSWORD}
- POSTGRES_DB=${DB_NAME}
volumes:
- postgres-db1:/var/lib/postgresql/data
ports:
- "5432:5432"
zookeeper:
image: 'bitnami/zookeeper:latest'
ports:
- '2181:2181'
environment:
- ALLOW_ANONYMOUS_LOGIN=yes
kafka:
image: 'bitnami/kafka:2.8.0'
ports:
- '9092:9092'
environment:
- KAFKA_ADVERTISED_LISTENERS=PLAINTEXT://kafka:9092
- ALLOW_PLAINTEXT_LISTENER=yes
- KAFKA_BROKER_ID=1
- KAFKA_CFG_LISTENERS=PLAINTEXT://:9092
- KAFKA_CFG_ADVERTISED_LISTENERS=PLAINTEXT://localhost:9092
- KAFKA_CFG_ZOOKEEPER_CONNECT=zookeeper:2181
- KAFKA_CFG_LOG_RETENTION_HOURS=6
depends_on:
- zookeeper
redis:
image: redis:alpine
restart: always
volumes:
- redis:/data
ports:
- 6379:6379
environment:
- REDIS_PASSWORD=1234
- REDIS_PORT=6379
- REDIS_DATABASES=16
redis-commander:
image: rediscommander/redis-commander:latest
environment:
- REDIS_HOSTS=local:redis:6379
- HTTP_USER=root
- HTTP_PASSWORD=1234
ports:
- 8081:8081
depends_on:
- redis
app:
image: trading-ui
build:
context: ./trading-ui
#target: production
dockerfile: Dockerfile
volumes:
- ./trading-ui:/app
- /node_modules
- /.next
ports:
- "3000:3000"
volumes:
postgres-db1:
redis:
redis-config: