forked from OcularEngineering/ocular
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.local.yml
107 lines (101 loc) · 2.84 KB
/
docker-compose.local.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
version: "3"
services:
ocular-models-server:
container_name: ocular-models-server
build:
context: .
dockerfile: packages/ocular-models-server/Dockerfile.models
ports:
- 8000:8000
qdrant:
image: qdrant/qdrant:latest
restart: always
container_name: qdrant
ports:
- 6333:6333
- 6334:6334
expose:
- 6333
- 6334
- 6335
volumes:
- ./qdrant_data:/qdrant_data
redis:
image: redis:latest
restart: always
ports:
- "6379:6379"
volumes:
- ./redis-data:/data
zookeeper:
image: "confluentinc/cp-zookeeper:latest"
ports:
- "2181:2181"
environment:
- ZOOKEEPER_CLIENT_PORT=2181
- ZOOKEEPER_TICK_TIME=2000
volumes:
- ./log4j.properties:/opt/bitnami/zookeeper/conf/log4j.properties
kafka:
image: confluentinc/cp-kafka:latest
user: root
ports:
- "9092:9092"
- "29092:29092"
depends_on:
- zookeeper
environment:
- KAFKA_BROKER_ID=1
- KAFKA_OFFSETS_TOPIC_REPLICATION_FACTOR=1
- KAFKA_LISTENERS=PLAINTEXT://:9092,EXTERNAL://kafka:29092
- KAFKA_ADVERTISED_LISTENERS=PLAINTEXT://:9092,EXTERNAL://kafka:29092
- KAFKA_ZOOKEEPER_CONNECT=zookeeper:2181
- KAFKA_LISTENER_SECURITY_PROTOCOL_MAP=PLAINTEXT:PLAINTEXT,EXTERNAL:PLAINTEXT
- ALLOW_PLAINTEXT_LISTENER=yes
- KAFKA_LOG4J_LOGGERS=org.apache.zookeeper=ERROR,org.apache.kafka=ERROR,kafka=ERROR,kafka.cluster=ERROR,kafka.controller=ERROR,kafka.coordinator=ERROR,kafka.log=ERROR,kafka.server=ERROR,kafka.zookeeper=ERROR,state.change.logger=ERROR
volumes:
- ./Kafka:/bitnami/kafka
- ./log4j.properties:/etc/kafka/log4j.properties
ocular-db:
image: postgres:14-alpine
ports:
- "5433:5432"
environment:
POSTGRES_PASSWORD: ocular
POSTGRES_USER: ocular
POSTGRES_DB: ocular
ocular-backend:
container_name: ocular-backend
build:
context: .
dockerfile: packages/ocular/Dockerfile.local
depends_on:
ocular-db:
condition: service_started
qdrant:
condition: service_started
ocular-models-server:
condition: service_started
kafka:
condition: service_started
ports:
- 9000:9000
command: /bin/sh -c "npm run typeorm:local migration:run && npm run local"
environment:
- DATABASE_URL=postgresql://ocular:ocular@ocular-db:5432/ocular
- DATABASE_NAME=ocular
- NODE_ENV=development
- QDRANT_DB_URL=http://qdrant:6333
- UI_CORS=http://ocular-ui:9000
- REDIS_URL=redis:6379
- KAFKA_URL=kafka:29092
- OCULAR_MODELS_SERVER_URL=http://ocular-models-server:8000
ocular-ui:
container_name: ocular-ui
build:
context: .
dockerfile: packages/ocular-ui/Dockerfile
ports:
- 3001:3001
depends_on:
- ocular-backend