komga/docker-compose.yml
duong.doan1 29692c738b feat: Complete Sprint 1 PostgreSQL infrastructure
- Add flyway-database-postgresql dependency
- Create DatabaseUdfProvider abstraction with SQLite/PostgreSQL implementations
- Update all DAO classes to use JooqUdfHelper for database-agnostic UDF/collation
- Implement dynamic JOOQ dialect configuration based on database type
- Add PostgreSQL migration directory with initial migration
- Create Docker Compose setup for PostgreSQL 16
- Add integration test with Testcontainers PostgreSQL
- Create helper scripts for local testing
- Update application.yml for simplified testing
- Add documentation and task tracking
2026-04-07 14:09:19 +07:00

46 lines
No EOL
1.1 KiB
YAML

version: '3.8'
services:
postgres:
image: postgres:16-alpine
container_name: komga-postgres
environment:
POSTGRES_DB: komga
POSTGRES_USER: komga
POSTGRES_PASSWORD: komga123
ports:
- "5433:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
- ./docker/postgres/init.sql:/docker-entrypoint-initdb.d/init.sql
healthcheck:
test: ["CMD-SHELL", "pg_isready -U komga"]
interval: 10s
timeout: 5s
retries: 5
komga:
build:
context: .
dockerfile: docker/Dockerfile
container_name: komga-backend
depends_on:
postgres:
condition: service_healthy
environment:
SPRING_PROFILES_ACTIVE: docker
KOMGA_DATABASE_TYPE: postgresql
KOMGA_DATABASE_URL: jdbc:postgresql://postgres:5432/komga
KOMGA_DATABASE_USERNAME: komga
KOMGA_DATABASE_PASSWORD: komga123
KOMGA_CONFIG_DIR: /config
ports:
- "25600:25600"
volumes:
- komga_config:/config
- ./data:/data:ro
restart: unless-stopped
volumes:
postgres_data:
komga_config: