-
Notifications
You must be signed in to change notification settings - Fork 15
/
Copy pathdocker-compose.yml
61 lines (57 loc) · 1.68 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
networks:
e2m-network:
driver: bridge
services:
postgres:
container_name: e2m-postgres
image: postgres:15-alpine
restart: always
environment:
POSTGRES_USER: e2m
POSTGRES_PASSWORD: password
POSTGRES_DB: e2m_db
volumes:
- postgres_data:/var/lib/postgresql/data
networks:
- e2m-network
healthcheck:
test: ["CMD-SHELL", "pg_isready -U e2m -d e2m_db"]
interval: 30s
timeout: 10s
retries: 5
e2m-api:
build: app/
container_name: e2m-api
ports:
- "8765:8765"
environment:
FLASK_APP: app.py
FLASK_ENV: production
API_URL: http://127.0.0.1:8765
WEB_URL: http://127.0.0.1:3000
TZ: Asia/Shanghai
DOC_CONVERTER: unstructured
DOCX_CONVERTER: unstructured
PDF_CONVERTER: unstructured
# ENABLE_LLM: "True"
# OPENAI_API_KEY: "sk-xxxxxx"
# OPENAI_API_BASE: "https://xxxxxxxxxxxxxxxxx"
USE_DB: "True"
SQLALCHEMY_DATABASE_URI: postgresql+psycopg2://e2m:password@postgres/e2m_db
SQLALCHEMY_BINDS: '{"e2m_db": "postgresql+psycopg2://e2m:password@postgres/e2m_db"}'
depends_on:
- postgres
networks:
- e2m-network
e2m-web:
build: web/
container_name: e2m-web
ports:
- "3000:3000"
environment:
API_URL: http://127.0.0.1:8765
NEXT_FONT_OPTIMIZATION: 'false'
networks:
- e2m-network
volumes:
postgres_data: