63 lines
1.4 KiB
YAML
63 lines
1.4 KiB
YAML
|
|
services:
|
|
|
|
postgres:
|
|
container_name: our-postgres
|
|
image: postgres:17
|
|
restart: unless-stopped
|
|
env_file: ./../../.env
|
|
ports:
|
|
- "5432:5432"
|
|
volumes:
|
|
- pgdata:/var/lib/postgresql/data
|
|
healthcheck:
|
|
test: ["CMD", "pg_isready", "-U", "postgres"]
|
|
interval: 10s
|
|
retries: 5
|
|
start_period: 10s
|
|
timeout: 10s
|
|
|
|
pgweb:
|
|
container_name: out-pgweb
|
|
image: sosedoff/pgweb
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
env_file: ./../../.env
|
|
ports:
|
|
- "8091:8081"
|
|
healthcheck:
|
|
test: ["CMD", "curl", "-f", "http://localhost:8081"]
|
|
interval: 10s
|
|
retries: 5
|
|
start_period: 10s
|
|
timeout: 10s
|
|
|
|
# pgadmin:
|
|
# image: dpage/pgadmin4:latest
|
|
# environment:
|
|
# PGADMIN_LISTEN_PORT: 5050
|
|
# PGADMIN_DEFAULT_EMAIL: ${PGADMIN_DEFAULT_EMAIL}
|
|
# PGADMIN_DEFAULT_PASSWORD: ${PGADMIN_DEFAULT_PASSWORD}
|
|
# PGADMIN_DISABLE_POSTFIX: true
|
|
# ports:
|
|
# - "5050:5050"
|
|
|
|
our:
|
|
build:
|
|
context: .
|
|
dockerfile: Dockerfile
|
|
container_name: our-app
|
|
ports:
|
|
- "5000:5000"
|
|
env_file: ./../../.env ## @see ./src/config/env.ts for all env var names.
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
networks:
|
|
- default
|
|
entrypoint: >
|
|
sh -c "npm run deploy && npm run start:server"
|
|
|
|
volumes:
|
|
pgdata: |