-
Notifications
You must be signed in to change notification settings - Fork 12
Expand file tree
/
Copy pathdocker-compose-prod.yml
More file actions
executable file
·169 lines (154 loc) · 5.43 KB
/
docker-compose-prod.yml
File metadata and controls
executable file
·169 lines (154 loc) · 5.43 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
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
services:
just-chat-agents:
container_name: just-chat-agents
# image: ghcr.io/longevity-genie/just-agents/chat-ui-agents:main
image: ghcr.io/longevity-genie/just-semantic-search/rag-server:main
environment:
# Web server configuration
APP_HOST: "0.0.0.0" # app host inside container, 0's to expose
APP_PORT: "8091" # app port inside container
# Agent core configuration
AGENT_TITLE: "Chat AGENTS REST API node"
AGENT_WORKERS: "1"
AGENT_SECTION: "" # for one agent
AGENT_PARENT_SECTION: "agent_profiles"
AGENT_FAILFAST: "true" # fail fast on startup in case of profile errors or just drop bad profiles
AGENT_DEBUG: "true"
AGENT_CONFIG_PATH: "/app/chat_agent_profiles.yaml"
# Agent connectivity for chat UI
AGENT_HOST: "http://just-chat-agents" # agent host for chat to access
AGENT_PORT: "8091" # agent port for chat to access
# Directory configuration
APP_DIR: "/app"
TMP_DIR: "tmp"
LOG_DIR: "logs"
DATA_DIR: "data"
MODELS_DIR: "/app/models.d" # used by chat-ui to get models
AGENT_USE_PROXY: True
AGENT_PROXY_ADDRESS: "http://litellm-proxy:4000/v1"
SECURITY_API_KEY: "sk-fancy_security_key"
# Environment files
ENV_KEYS_PATH: "/app/env/.env.keys" # used by agents to get keys
ENV_MODELS_PATH: "/app/env/.env.local" # used by chat-ui to get models
# Additional configuration options
TRAP_CHAT_NAMES: "true" #re-route naming to dedicated agent or use default (first in list) agent intead for this purpose
# User/group configuration
USER_ID: ${USER_ID:-${UID}}
GROUP_ID: ${GROUP_ID:-${GID}}
# Meilisearch configuration
MEILI_MASTER_KEY: "fancy_master_key"
MEILISEARCH_HOST: "meilisearch"
MEILISEARCH_PORT: 7700
MEILISEARCH_SEMANTIC_RATIO: 0.7
# RAG configuration
EMBEDDING_MODEL: "jinaai/jina-embeddings-v3"
INDEX_CHARACTERS_FOR_ABSTRACT: 100000
INDEX_MAX_SEQ_LENGTH: 36000
ports:
- "127.0.0.1:8091:8091"
#entrypoint: [ "/usr/local/bin/entrypoint.sh" ]
healthcheck:
test: ["CMD-SHELL", "curl -s 0.0.0.0:8091/docs | grep 'Swagger' && test -f ./env/.env.local"]
interval: 15s
retries: 10
start_period: 15s
timeout: 1s
volumes:
# - "./scripts/replacement_entrypoint.sh:/usr/local/bin/entrypoint.sh"
- "./scripts/init_env.py:/app/init.py"
- "./data:/app/data"
- "./env:/app/env"
- "./logs:/app/logs"
- "./scripts:/app/scripts"
- "./agent_tools:/app/agent_tools"
- "./chat_agent_profiles.yaml:/app/chat_agent_profiles.yaml"
depends_on:
litellm-proxy:
condition: service_started
restart: on-failure:3
# command: ["python", "-m", "just_agents.web.run_agent", "run-chat-ui-server-command"]
command: "python -m just_semantic_search.server.run_rag_server --workers 1 --agent-profiles /app/chat_agent_profiles.yaml"
huggingchat-ui:
container_name: chat-ui
image: ghcr.io/longevity-genie/chat-ui/chat-ui:latest
# image: ghcr.io/longevity-genie/chat-ui/chat-ui:sha-6b47a62
environment:
ALLOW_INSECURE_COOKIES: "true"
INCLUDE_DB: "False"
volumes:
- "./env/.env.local:/app/.env.local"
ports:
- "0.0.0.0:3000:3000"
depends_on:
just-chat-agents:
condition: service_healthy
chat-mongo:
condition: service_started
restart: unless-stopped
chat-mongo:
container_name: just-chat-mongodb-for-agents
image: docker.io/library/mongo:latest
restart: always
env_file:
- ./env/.env.mongo
ports:
- "27017"
volumes:
- "mongo-data:/data/db"
# - "./volumes/mongo/db:/data/db"
depends_on:
just-chat-agents:
condition: service_healthy
meilisearch:
image: docker.io/getmeili/meilisearch:v1.26.0
environment:
- http_proxy
- https_proxy
- MEILI_MASTER_KEY=fancy_master_key
- MEILI_NO_ANALYTICS=true
- MEILI_ENV=development
- MEILI_LOG_LEVEL=debug
- MEILI_DB_PATH=/data.ms
- MEILI_EXPERIMENTAL_ENABLE_METRICS=true
- MEILI_EXPERIMENTAL_ENABLE_VECTORS=true
- MEILI_EXPERIMENTAL_DUMPESS_UPGRADE=true
ports:
- 7700:7700
#cap_add: # uncomment this section if you experience permissions issues in podman
# - DAC_OVERRIDE
volumes:
- meili-data:/data.ms
restart: unless-stopped
command: "meilisearch --experimental-dumpless-upgrade"
litellm-proxy:
container_name: litellm-proxy
image: ghcr.io/berriai/litellm:main-latest
command: '--config proxy_server_config.yaml --detailed_debug'
volumes:
- "./proxy.yaml:/app/proxy_server_config.yaml"
ports:
- "127.0.0.1:14000:4000" # Map the container port to the host, change the host port if necessary
env_file:
- ./env/.env.keys # Load local .env file
- ./env/.env.redis # Load local .env file
depends_on:
llm-cache:
condition: service_started
llm-cache:
container_name: just-litellm-cache-redis
image: redis:7.4-alpine
restart: unless-stopped
command: /bin/sh -c "redis-server --loglevel notice --requirepass $$REDIS_PASSWORD --port $$REDIS_PORT"
env_file:
- ./env/.env.redis
ports:
- "127.0.0.1:16379:6379"
volumes:
- redis-data:/bitnami/redis/data
volumes:
mongo-data:
meili-data:
redis-data:
networks:
default:
name: chat-server-for-agents