-
Notifications
You must be signed in to change notification settings - Fork 28
/
docker-compose-rag.yml
253 lines (236 loc) · 8.6 KB
/
docker-compose-rag.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
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
# WARNING to run this you need to ensure that vm.max_map_count is correctly configured
# See https://opensearch.org/docs/latest/install-and-configure/install-opensearch/docker#important-host-settings
# We recommande having at least 40Gb free space on your disk to prevent this error : https://stackoverflow.com/a/67767478
# If you have less and something goes wrong at the cluster boot check that you don't have any logs "high disk watermark [90%] exceeded"
# if so make some free space a few Gb until this error desapear.
version: '3'
services:
mongo:
image: "${PLATFORM}mongo:${MONGO}"
volumes:
- tockmongo:/data/db
ports:
- "27017:27017"
command: --bind_ip_all --port 27017 --replSet "tock"
mongo2:
image: "${PLATFORM}mongo:${MONGO}"
depends_on:
- mongo
volumes:
- tockmongo2:/data/db
ports:
- "27018:27018"
command: --bind_ip_all --port 27018 --replSet "tock"
mongo3:
image: "${PLATFORM}mongo:${MONGO}"
depends_on:
- mongo
- mongo2
volumes:
- tockmongo3:/data/db
ports:
- "27019:27019"
command: --bind_ip_all --port 27019 --replSet "tock"
mongo-setup:
container_name: "mongo-setup"
image: "${PLATFORM}mongo:${MONGO}"
depends_on:
- "mongo"
- "mongo2"
- "mongo3"
links:
- mongo:mongo
- mongo2:mongo2
- mongo3:mongo3
volumes:
- ./scripts:/scripts
environment:
- MONGO1=mongo
- MONGO2=mongo2
- MONGO3=mongo3
- RS=tock
entrypoint: [ "/scripts/setup.sh" ]
build_worker:
image: "${PLATFORM}tock/build_worker:${TAG}"
depends_on:
- mongo
- mongo2
- mongo3
environment:
- tock_mongo_url=mongodb://mongo:27017,mongo2:27018,mongo3:27019/?replicaSet=tock
- tock_env=prod
- JAVA_ARGS=-Xmx1g -XX:MaxMetaspaceSize=256m
# - tock_default_log_level=warn
# - tock_service_log_level=info
# - tock_database_log_level=warn
duckling:
image: "${PLATFORM}tock/duckling:${TAG}"
environment:
- tock_env=prod
# - tock_default_log_level=warn
# - tock_service_log_level=info
# - tock_database_log_level=warn
expose:
- "8080"
kotlin_compiler:
image: "${PLATFORM}tock/kotlin_compiler:${TAG}"
environment:
- tock_env=prod
- tock_kotlin_compiler_classpath=/maven
# - tock_default_log_level=warn
# - tock_service_log_level=info
# - tock_database_log_level=warn
expose:
- "8080"
admin_web:
image: "${PLATFORM}tock/bot_admin:${TAG}"
depends_on:
- mongo
- mongo2
- mongo3
- duckling
- kotlin_compiler
environment:
- no_proxy=duckling,bot_api,kotlin_compiler
- NO_PROXY=duckling,bot_api,kotlin_compiler
- tock_mongo_url=mongodb://mongo:27017,mongo2:27018,mongo3:27019/?replicaSet=tock
- nlp_duckling_url=http://duckling:8080
- tock_env=prod
- tock_file_upload_directory=file-uploads # custom directory for vert.x upload file system
- tock_namespace_open_access=true # Enabling/Disabling bot synchronization feature
- tock_bot_admin_rest_default_base_url=http://bot_api:8080
- tock_bot_compiler_service_url=http://kotlin_compiler:8080
- tock_configuration_bot_default_base_url=http://bot_api:8080
- tock_gen_ai_orchestrator_server_url=http://gen_ai_orchestrator-server:8000
- tock_gen_ai_orchestrator_client_request_timeout_ms=55000
- tock_gen_ai_orchestrator_technical_error=Technical error :( sorry!
#remove this in production
- tock_https_env=false
- botadminverticle_body_limit=-1
- tock_passwords=password,password,password,password,password,password,password,password
- tock_roles=nlpUser|botUser|admin|technicalAdmin,nlpUser|botUser|admin,nlpUser|botUser,nlpUser|botUser,nlpUser,botUser,admin,technicalAdmin
- tock_organizations=app,app,app,app,app,app,app,app
- tock_default_log_level=debug
- tock_service_log_level=debug
# - tock_database_log_level=warn
ports:
- "80:8080"
nlp_api:
image: "${PLATFORM}tock/nlp_api:${TAG}"
depends_on:
- mongo
- mongo2
- mongo3
- duckling
environment:
- no_proxy=duckling #Prevent traffic from using environment proxy
- NO_PROXY=duckling
- tock_mongo_url=mongodb://mongo:27017,mongo2:27018,mongo3:27019/?replicaSet=tock
- nlp_duckling_url=http://duckling:8080
- tock_env=prod
- tock_web_use_default_cors_handler=true
- tock_web_use_default_cors_handler_with_credentials=false
- tock_web_use_default_cors_handler_url=*
# - tock_default_log_level=warn
# - tock_service_log_level=info
# - tock_database_log_level=warn
ports:
- "8888:8080"
bot_api:
image: "${PLATFORM}tock/bot_api:${TAG}"
depends_on:
- mongo
- mongo2
- mongo3
- nlp_api
environment:
- no_proxy=nlp_api #Prevent traffic from using environment proxy
- NO_PROXY=nlp_api
- tock_mongo_url=mongodb://mongo:27017,mongo2:27018,mongo3:27019/?replicaSet=tock
- tock_nlp_service_url=http://nlp_api:8080
- tock_env=integ
- tock_websocket_enabled=true
- tock_gen_ai_orchestrator_server_url=http://gen_ai_orchestrator-server:8000
- tock_gen_ai_orchestrator_client_request_timeout_ms=55000
- tock_gen_ai_orchestrator_technical_error=Technical error :( sorry!
- tock_gen_ai_orchestrator_document_number_neighbors=1
- tock_gen_ai_orchestrator_dialog_number_messages=5
- tock_gen_ai_orchestrator_rag_debug_enabled=false
- tock_gen_ai_orchestrator_vector_store_provider=OpenSearch
# - tock_default_log_level=warn
# - tock_service_log_level=info
# - tock_database_log_level=warn
ports:
- "8080:8080"
opensearch-node1:
image: "${PLATFORM}opensearchproject/opensearch:${OPENSEARCH}"
environment:
- cluster.name=opensearch-cluster
- node.name=opensearch-node1
- discovery.seed_hosts=opensearch-node1,opensearch-node2
- cluster.initial_cluster_manager_nodes=opensearch-node1,opensearch-node2
- bootstrap.memory_lock=true # along with the memlock settings below, disables swapping
- "OPENSEARCH_JAVA_OPTS=-Xms512m -Xmx512m" # minimum and maximum Java heap size, recommend setting both to 50% of system RAM
ulimits:
memlock:
soft: -1
hard: -1
nofile:
soft: 65536 # maximum number of open files for the OpenSearch user, set to at least 65536 on modern systems
hard: 65536
volumes:
- opensearch-data1:/usr/share/opensearch/data
ports:
- 9200:9200
- 9600:9600 # required for Performance Analyzer
opensearch-node2:
image: "${PLATFORM}opensearchproject/opensearch:${OPENSEARCH}"
environment:
- cluster.name=opensearch-cluster
- node.name=opensearch-node2
- discovery.seed_hosts=opensearch-node1,opensearch-node2
- cluster.initial_cluster_manager_nodes=opensearch-node1,opensearch-node2
- bootstrap.memory_lock=true
- "OPENSEARCH_JAVA_OPTS=-Xms512m -Xmx512m"
ulimits:
memlock:
soft: -1
hard: -1
nofile:
soft: 65536
hard: 65536
volumes:
- opensearch-data2:/usr/share/opensearch/data
opensearch-dashboards:
image: "${PLATFORM}opensearchproject/opensearch-dashboards:${OPENSEARCH}"
ports:
- 5601:5601
expose:
- "5601"
environment:
OPENSEARCH_HOSTS: '["https://opensearch-node1:9200","https://opensearch-node2:9200"]'
gen_ai_orchestrator-server:
image: "${PLATFORM}tock/gen-ai-orchestrator-server:${TAG}"
ports:
- "8000:8000"
environment:
tock_gen_ai_orchestrator_application_environment: DEV
tock_gen_ai_orchestrator_em_provider_timeout: 120
tock_gen_ai_orchestrator_llm_provider_timeout: 120
tock_gen_ai_orchestrator_llm_provider_max_retries: 0
tock_gen_ai_orchestrator_vector_store_provider: OpenSearch
tock_gen_ai_orchestrator_vector_store_host: opensearch-node1
tock_gen_ai_orchestrator_vector_store_port: 9200
tock_gen_ai_orchestrator_vector_store_user: admin
tock_gen_ai_orchestrator_vector_store_pwd: admin
tock_gen_ai_orchestrator_vector_store_database:
tock_gen_ai_orchestrator_vector_store_timeout: 5
tock_gen_ai_orchestrator_vector_store_secret_manager_provider:
tock_gen_ai_orchestrator_vector_store_credentials_secret_name:
volumes:
tockmongo:
tockmongo2:
tockmongo3:
opensearch-data1:
opensearch-data2: