TenantAtlas/docker-compose.yml
ahmido dbff2a0a90 feat(report): implement management report pdf runtime (#450)
Added jobs, controllers, and PDF generation logic for management report runtime as defined in Spec 379. Includes artifact migrations, payload builders, and testing coverage.

Co-authored-by: Ahmed Darrazi <ahmed.darrazi@live.de>
Reviewed-on: #450
2026-06-15 11:36:29 +00:00

130 lines
3.8 KiB
YAML

services:
laravel.test:
build:
context: ./apps/platform/vendor/laravel/sail/runtimes/8.4
dockerfile: Dockerfile
args:
WWWGROUP: '${WWWGROUP:-1000}'
NODE_VERSION: '20'
image: tenantatlas-laravel
extra_hosts:
- 'host.docker.internal:host-gateway'
ports:
- '${APP_PORT:-80}:80'
- '${VITE_PORT:-5173}:${VITE_PORT:-5173}'
environment:
WWWUSER: '${WWWUSER:-1000}'
WWWGROUP: '${WWWGROUP:-1000}'
LARAVEL_SAIL: 1
APP_SERVICE: laravel.test
TENANTATLAS_REPO_ROOT: /var/www/repo
entrypoint: ["/bin/sh", "-c", "mkdir -p /var/www/html/node_modules && chown ${WWWUSER:-1000}:${WWWGROUP:-1000} /var/www/html/node_modules || true; exec start-container"]
working_dir: /var/www/html
volumes:
- './apps/platform:/var/www/html'
- '.:/var/www/repo:ro'
- '/var/www/html/node_modules'
networks:
- sail
depends_on:
- pgsql
- redis
- gotenberg
queue:
build:
context: ./apps/platform/vendor/laravel/sail/runtimes/8.4
dockerfile: Dockerfile
args:
WWWGROUP: '${WWWGROUP:-1000}'
NODE_VERSION: '20'
image: tenantatlas-laravel
extra_hosts:
- 'host.docker.internal:host-gateway'
environment:
WWWUSER: '${WWWUSER:-1000}'
WWWGROUP: '${WWWGROUP:-1000}'
LARAVEL_SAIL: 1
APP_SERVICE: queue
TENANTATLAS_REPO_ROOT: /var/www/repo
entrypoint:
- /bin/sh
- -c
- mkdir -p /var/www/html/node_modules && chown ${WWWUSER:-1000}:${WWWGROUP:-1000} /var/www/html/node_modules || true; exec start-container "$@"
- --
working_dir: /var/www/html
volumes:
- './apps/platform:/var/www/html'
- '.:/var/www/repo:ro'
- '/var/www/html/node_modules'
networks:
- sail
depends_on:
- laravel.test
- pgsql
- redis
- gotenberg
command: php artisan queue:listen --tries=3 --timeout=300 --sleep=3
gotenberg:
image: 'gotenberg/gotenberg:8.34.0-chromium'
environment:
API_TIMEOUT: '${GOTENBERG_API_TIMEOUT:-30s}'
API_BODY_LIMIT: '${GOTENBERG_API_BODY_LIMIT:-10MB}'
API_CORRELATION_ID_HEADER: '${GOTENBERG_API_CORRELATION_ID_HEADER:-Gotenberg-Trace}'
API_DISABLE_DOWNLOAD_FROM: 'true'
API_ENABLE_DEBUG_ROUTE: 'false'
CHROMIUM_AUTO_START: 'true'
CHROMIUM_START_TIMEOUT: '${GOTENBERG_CHROMIUM_START_TIMEOUT:-20s}'
CHROMIUM_MAX_QUEUE_SIZE: '${GOTENBERG_CHROMIUM_MAX_QUEUE_SIZE:-10}'
CHROMIUM_MAX_CONCURRENCY: '${GOTENBERG_CHROMIUM_MAX_CONCURRENCY:-2}'
CHROMIUM_ALLOW_FILE_ACCESS_FROM_FILES: '${GOTENBERG_CHROMIUM_ALLOW_FILE_ACCESS_FROM_FILES:-true}'
CHROMIUM_ALLOW_LIST: '${GOTENBERG_CHROMIUM_ALLOW_LIST:-^file:///tmp/.*$}'
CHROMIUM_DENY_PRIVATE_IPS: 'true'
CHROMIUM_DENY_PUBLIC_IPS: 'true'
WEBHOOK_DISABLE: 'true'
WEBHOOK_DENY_PRIVATE_IPS: 'true'
WEBHOOK_DENY_PUBLIC_IPS: 'true'
API_DOWNLOAD_FROM_DENY_PRIVATE_IPS: 'true'
API_DOWNLOAD_FROM_DENY_PUBLIC_IPS: 'true'
healthcheck:
test: ["CMD-SHELL", "wget -qO- http://127.0.0.1:3000/health >/dev/null 2>&1 || exit 1"]
interval: 30s
timeout: 5s
retries: 3
start_period: 20s
networks:
- sail
pgsql:
image: 'postgres:16'
ports:
- '${FORWARD_DB_PORT:-5432}:5432'
environment:
POSTGRES_DB: '${DB_DATABASE:-tenantatlas}'
POSTGRES_USER: '${DB_USERNAME:-root}'
POSTGRES_PASSWORD: '${DB_PASSWORD:-postgres}'
volumes:
- 'sail-pgsql:/var/lib/postgresql/data'
networks:
- sail
redis:
image: 'redis:7-alpine'
ports:
- '${FORWARD_REDIS_PORT:-6379}:6379'
volumes:
- 'sail-redis:/data'
networks:
- sail
volumes:
sail-pgsql:
driver: local
sail-redis:
driver: local
networks:
sail:
driver: bridge