update compose for monorepo
Build and Push Docker Images / Build and Push Docker Images (push) Failing after 28s
Build and Push Docker Images / Build and Push Docker Images (push) Failing after 28s
This commit is contained in:
+34
@@ -0,0 +1,34 @@
|
||||
services:
|
||||
backend:
|
||||
build:
|
||||
context: .build/dev
|
||||
hostname: backend
|
||||
volumes:
|
||||
- ./:/app
|
||||
ports:
|
||||
- 5000:5000
|
||||
env_file:
|
||||
- .env
|
||||
depends_on:
|
||||
database:
|
||||
condition: service_healthy
|
||||
|
||||
database:
|
||||
image: postgres:16
|
||||
hostname: database
|
||||
environment:
|
||||
POSTGRES_DB: ${POSTGRES_DATABASE:-sarlink}
|
||||
POSTGRES_USER: ${POSTGRES_USER:-sarlink}
|
||||
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-changeme}
|
||||
volumes:
|
||||
- pgdata:/var/lib/postgresql/data
|
||||
ports:
|
||||
- 5432:5432
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "pg_isready -U $${POSTGRES_USER:-sarlink}"]
|
||||
interval: 5s
|
||||
timeout: 3s
|
||||
retries: 10
|
||||
|
||||
volumes:
|
||||
pgdata:
|
||||
Reference in New Issue
Block a user