generated from VLADIMIR/template
41 lines
993 B
YAML
41 lines
993 B
YAML
version: '3.8'
|
|
|
|
networks:
|
|
app_network:
|
|
driver: bridge
|
|
|
|
services:
|
|
evening_detective_server:
|
|
build:
|
|
context: .
|
|
dockerfile: Dockerfile
|
|
ports:
|
|
- "8080:8080"
|
|
environment:
|
|
- DATABASE_URL: "postgresql://postgres:postgres@postgres:5432/evening_detective_server?sslmode=disable"
|
|
depends_on:
|
|
- postgres
|
|
restart: unless-stopped
|
|
networks:
|
|
- app_network
|
|
|
|
postgres:
|
|
image: postgres:15
|
|
container_name: postgres_evening_detective_server
|
|
environment:
|
|
POSTGRES_USER: postgres
|
|
POSTGRES_PASSWORD: detective
|
|
POSTGRES_DB: evening_detective_server
|
|
TZ: Asia/Barnaul # Для системного времени контейнера
|
|
PGTZ: Asia/Barnaul # Специфичная для PostgreSQL переменная
|
|
ports:
|
|
- "5432:5432"
|
|
volumes:
|
|
- postgres_data:/var/lib/postgresql/data
|
|
restart: unless-stopped
|
|
networks:
|
|
- app_network
|
|
|
|
volumes:
|
|
postgres_data:
|