78 lines
1.4 KiB
YAML
78 lines
1.4 KiB
YAML
|
|
services:
|
|
postgres:
|
|
image: postgres
|
|
restart: unless-stopped
|
|
environment:
|
|
- POSTGRES_DB=kontor
|
|
- POSTGRES_USER=kontor
|
|
#- POSTGRES_PASSWORD_FILE=/run/secrets/db-password
|
|
- POSTGRES_PASSWORD=kontor
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "pg_isready -U kontor"]
|
|
interval: 1s
|
|
timeout: 5s
|
|
retries: 10
|
|
ports:
|
|
- 5432:5432
|
|
networks:
|
|
- database
|
|
volumes:
|
|
- postgres-data:/var/lib/postgresql/data:rw
|
|
secrets:
|
|
- db-password
|
|
adminer:
|
|
image: adminer
|
|
ports:
|
|
- 8090:8080
|
|
networks:
|
|
- database
|
|
- frontend
|
|
mariadb:
|
|
image: mariadb
|
|
restart: unless-stopped
|
|
environment:
|
|
MYSQL_ROOT_PASSWORD: kontor
|
|
MYSQL_USER: kontor
|
|
MYSQL_PASSWORD: kontor
|
|
MYSQL_DATABASE: kontor
|
|
ports:
|
|
- 3316:3306
|
|
networks:
|
|
- database
|
|
volumes:
|
|
- mariadb-storage:/var/lib/mysql:rw
|
|
kontor:
|
|
image: kontor:0.1.0
|
|
restart: unless-stopped
|
|
networks:
|
|
- database
|
|
- frontend
|
|
ports:
|
|
- 8000:8000
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
kontor-api:
|
|
image: kontor-api:0.1.0
|
|
restart: unless-stopped
|
|
networks:
|
|
- database
|
|
- frontend
|
|
ports:
|
|
- 8800:8800
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
|
|
networks:
|
|
database:
|
|
frontend:
|
|
volumes:
|
|
mariadb-storage:
|
|
postgres-data:
|
|
secrets:
|
|
db-password:
|
|
file: db-password.txt
|
|
|