Docker fix (#114)

* fix: db healthcheck

* fixed missing front build argument

* fix: db healthcheck user

* message from db 'user' doesnt exist fixed

* rm: useless yarn

Co-authored-by: GitBluub <louis.auzuret@gmail.com>
This commit is contained in:
Clément Le Bihan
2022-12-20 18:35:34 +01:00
committed by GitHub
parent 6312fc3337
commit 56fdadc705
4 changed files with 62 additions and 4 deletions

View File

@@ -4,7 +4,8 @@ services:
ports:
- "3000:3000"
depends_on:
- "db"
db:
condition: service_healthy
env_file:
- .env
volumes:
@@ -18,8 +19,17 @@ services:
- POSTGRES_DB=${POSTGRES_DB}
ports:
- "5432:5432"
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER} -d ${POSTGRES_DB}"]
interval: 5s
timeout: 5s
retries: 5
front:
build: ./front
build:
context: ./front
args:
- API_URL=${API_URL}
ports:
- "80:80"
depends_on: