generated from DefangSamples/sample-RAG-chatbot-template
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcompose.yaml
30 lines (30 loc) · 838 Bytes
/
compose.yaml
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
services:
rag-chatbot:
restart: always
domainname: ask.defang.io
x-defang-dns-role: arn:aws:iam::258338292852:role/dnsadmin-39a19c3
build:
context: ./app
shm_size: "16gb"
ports:
- target: 5000
published: 5000
protocol: tcp
mode: ingress
environment:
FLASK_APP: app.py
SECRET_KEY:
SEGMENT_WRITE_KEY:
SESSION_COOKIE_SECURE: 1
OPENAI_API_KEY: ${OPENAI_API_KEY} # Set your OpenAI API key here or in the .env file
command: uwsgi --http 0.0.0.0:5000 --wsgi-file app.py --callable app --processes 4 --threads 2
deploy:
resources:
reservations:
memory: 4G
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:5000/"]
interval: 30s
timeout: 10s
retries: 5
#start_period: 40s