38 lines
774 B
YAML
38 lines
774 B
YAML
|
version: '3.3'
|
||
|
|
||
|
services:
|
||
|
db:
|
||
|
image: postgres
|
||
|
shm_size: 128mb
|
||
|
env_file: .env
|
||
|
volumes:
|
||
|
- data:/var/lib/postgresql/data
|
||
|
healthcheck:
|
||
|
test: [ "CMD-SHELL", "pg_isready -U app -d app" ]
|
||
|
interval: 30s
|
||
|
timeout: 30s
|
||
|
retries: 5
|
||
|
restart: unless-stopped
|
||
|
app:
|
||
|
image: gitrepo.ru/neonxp/app:latest
|
||
|
volumes:
|
||
|
- config:/config
|
||
|
command: serve -config=/config/prod.yaml
|
||
|
depends_on:
|
||
|
db:
|
||
|
condition: service_healthy
|
||
|
ports:
|
||
|
- 8093:8000
|
||
|
restart: unless-stopped
|
||
|
migration:
|
||
|
image: gitrepo.ru/neonxp/app:latest
|
||
|
volumes:
|
||
|
- config:/config
|
||
|
command: db migrate -config=/config/prod.yaml
|
||
|
depends_on:
|
||
|
db:
|
||
|
condition: service_healthy
|
||
|
volumes:
|
||
|
data:
|
||
|
config:
|