Add QDrant to onebox setup

This commit is contained in:
Weves 2023-05-07 12:20:23 -07:00 committed by Chris Weaver
parent 9babe7fb95
commit ab36ebc332
2 changed files with 13 additions and 9 deletions

View File

@ -7,6 +7,7 @@ RUN apt-get update \
COPY ./requirements/default.txt /tmp/requirements.txt
RUN pip install --no-cache-dir --upgrade -r /tmp/requirements.txt
RUN playwright install
RUN playwright install-deps
WORKDIR /app
COPY ./danswer /app/danswer

View File

@ -1,4 +1,3 @@
# follows https://pentacent.medium.com/nginx-and-lets-encrypt-with-docker-in-less-than-5-minutes-b4b8a60d3a71
version: '3'
services:
api:
@ -7,6 +6,7 @@ services:
dockerfile: Dockerfile
depends_on:
- db
- qdrant
# uncomment for local testing
# ports:
# - "8080:8080"
@ -14,6 +14,7 @@ services:
- .env
environment:
- POSTGRES_HOST=db
- QDRANT_HOST=qdrant
volumes:
- local_dynamic_storage:/home/storage
background:
@ -22,20 +23,18 @@ services:
dockerfile: Dockerfile.background
depends_on:
- db
- qdrant
env_file:
- .env
environment:
- POSTGRES_HOST=db
- QDRANT_HOST=qdrant
volumes:
- local_dynamic_storage:/home/storage
web:
build:
context: ../web
dockerfile: Dockerfile
args:
NEXT_PUBLIC_API_URL: /api
depends_on:
- api
db:
image: postgres:15.2-alpine
restart: always
@ -45,7 +44,11 @@ services:
ports:
- "5432:5432"
volumes:
- db:/var/lib/postgresql/data
- db_volume:/var/lib/postgresql/data
qdrant:
image: qdrant/qdrant:v1.1.3
volumes:
- qdrant_volume:/qdrant/storage
nginx:
image: nginx:1.23.4-alpine
ports:
@ -60,8 +63,7 @@ services:
&& while :; do sleep 6h & wait $${!}; nginx -s reload; done & nginx -g \"daemon off;\""
env_file:
- .env.nginx
depends_on:
- api
# follows https://pentacent.medium.com/nginx-and-lets-encrypt-with-docker-in-less-than-5-minutes-b4b8a60d3a71
certbot:
image: certbot/certbot
volumes:
@ -70,4 +72,5 @@ services:
entrypoint: "/bin/sh -c 'trap exit TERM; while :; do certbot renew; sleep 12h & wait $${!}; done;'"
volumes:
local_dynamic_storage:
db:
db_volume:
qdrant_volume: