feat: optimize docker build pipeline with dockerignore, automated entrypoint migrations, and configurable compose image
Build and Push Docker Image / build-and-push (push) Failing after 1m1s
Build and Push Docker Image / build-and-push (push) Failing after 1m1s
This commit is contained in:
+7
-15
@@ -17,24 +17,16 @@ services:
|
||||
timeout: 5s
|
||||
retries: 5
|
||||
|
||||
migrate:
|
||||
build: .
|
||||
container_name: checkflow-migrate
|
||||
depends_on:
|
||||
postgres:
|
||||
condition: service_healthy
|
||||
environment:
|
||||
DATABASE_URL: postgresql://checkflow:${POSTGRES_PASSWORD:-changeme}@postgres:5432/checkflow
|
||||
command: npx prisma migrate deploy
|
||||
restart: "no"
|
||||
|
||||
app:
|
||||
build: .
|
||||
image: ${CHECKFLOW_IMAGE:-checkflow:latest}
|
||||
build:
|
||||
context: .
|
||||
dockerfile: Dockerfile
|
||||
container_name: checkflow-app
|
||||
restart: unless-stopped
|
||||
depends_on:
|
||||
migrate:
|
||||
condition: service_completed_successfully
|
||||
postgres:
|
||||
condition: service_healthy
|
||||
ports:
|
||||
- "${PORT:-3000}:3000"
|
||||
environment:
|
||||
@@ -46,4 +38,4 @@ services:
|
||||
- ./prisma:/app/prisma
|
||||
|
||||
volumes:
|
||||
postgres_data:
|
||||
postgres_data:
|
||||
|
||||
Reference in New Issue
Block a user