data1 / docker-compose.yml
blaze-aura69's picture
Create docker-compose.yml
1c788e0 verified
Raw
History Blame
667 Bytes
version: '3.8'
services:
postgres:
image: postgres:16-alpine
environment:
POSTGRES_DB: velost
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
ports:
- "5432:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres"]
interval: 5s
timeout: 5s
retries: 5
app:
build: .
ports:
- "7860:7860"
environment:
PGHOST: postgres
PGPORT: 5432
PGDATABASE: velost
PGUSER: postgres
PGPASSWORD: postgres
depends_on:
postgres:
condition: service_healthy
volumes:
postgres_data: