File tree Expand file tree Collapse file tree 2 files changed +10
-2
lines changed Expand file tree Collapse file tree 2 files changed +10
-2
lines changed Original file line number Diff line number Diff line change 3838* .tmp
3939txt.txt
4040credentials.json
41+ docker-compose.override.yml
Original file line number Diff line number Diff line change @@ -11,8 +11,10 @@ services:
1111 depends_on :
1212 - db
1313 command : bash -c "alembic upgrade head && uvicorn app.main:app --host 0.0.0.0 --port 8000"
14- volumes :
15- - ./alembic/versions:/app/alembic/versions
14+ depends_on :
15+ db :
16+ # This now waits for the db to be healthy, not just started
17+ condition : service_healthy
1618
1719 db :
1820 image : postgres:14
@@ -27,6 +29,11 @@ services:
2729 - postgres_data:/var/lib/postgresql/data
2830 ports :
2931 - " 5432:5432"
32+ healthcheck :
33+ test : ["CMD-SHELL", "pg_isready -U ammentor_user -d praveshan-ammentor"]
34+ interval : 5s
35+ timeout : 5s
36+ retries : 5
3037
3138volumes :
3239 postgres_data :
You can’t perform that action at this time.
0 commit comments