aboutsummaryrefslogtreecommitdiffstats
path: root/docker-compose.yml
diff options
context:
space:
mode:
authorGravatar Chris Lovering <[email protected]>2024-08-16 17:53:52 +0100
committerGravatar Chris Lovering <[email protected]>2024-08-16 17:53:52 +0100
commit71d1ea51a4e9ccafd56bdcb5dba126f2b1831a36 (patch)
tree354c4d5c077036b22db6d1a8717fdb1540807929 /docker-compose.yml
parentAdd a basic litestar app (diff)
Move to fastapi & mono repo layout
Diffstat (limited to 'docker-compose.yml')
-rw-r--r--docker-compose.yml28
1 files changed, 23 insertions, 5 deletions
diff --git a/docker-compose.yml b/docker-compose.yml
index b57b147..f3f9844 100644
--- a/docker-compose.yml
+++ b/docker-compose.yml
@@ -1,11 +1,29 @@
services:
+ postgres:
+ restart: unless-stopped
+ image: postgres:16-alpine
+ environment:
+ POSTGRES_DB: thallium
+ POSTGRES_PASSWORD: thallium
+ POSTGRES_USER: thallium
+ healthcheck:
+ test: ["CMD-SHELL", "pg_isready -U thallium"]
+ interval: 2s
+ timeout: 1s
+ retries: 5
+ ports:
+ - "15432:5432"
+
thallium:
- build: .
+ build: thallium-backend
restart: unless-stopped
- command: ["thallium.app:app", "--host", "0.0.0.0", "--port", "80", "--reload"]
- volumes:
- - ./thallium:/thallium/thallium:ro
+ command: ["src.app:fastapi_app", "--host", "0.0.0.0", "--port", "80", "--reload"]
+ # volumes:
+ # - ./thallium:/thallium/thallium:ro
env_file:
- .env
ports:
- - "127.0.0.1:8000:80"
+ - "8000:80"
+ depends_on:
+ postgres:
+ condition: service_healthy