refactor(infra) : align prod setup with Lesstime pattern
Some checks failed
Auto Tag Develop / tag (push) Has been cancelled

Single container with supervisord (Nginx + PHP-FPM), 3-stage
Dockerfile build, pre-built image from registry, port 8086.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Matthieu
2026-04-07 14:53:10 +02:00
parent 34adb01cbb
commit 389bfbef13
5 changed files with 115 additions and 122 deletions

View File

@@ -1,42 +1,12 @@
services:
php:
container_name: php-coltura-fpm
build:
context: ../../
dockerfile: infra/prod/Dockerfile
target: php-base
environment:
APP_ENV: prod
APP_DEBUG: 0
DATABASE_URL: "postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@db:5432/${POSTGRES_DB}?serverVersion=16&charset=utf8"
volumes:
- uploads_data:/var/www/html/var/uploads
depends_on:
- db
restart: unless-stopped
nginx:
container_name: nginx-coltura
build:
context: ../../
dockerfile: infra/prod/Dockerfile
target: nginx
depends_on:
- php
app:
image: gitea.malio.fr/malio-dev/coltura:${COLTURA_IMAGE_TAG:-latest}
container_name: coltura-app
env_file: .env
ports:
- "8086:80"
restart: unless-stopped
db:
image: postgres:16-alpine
environment:
POSTGRES_DB: ${POSTGRES_DB}
POSTGRES_USER: ${POSTGRES_USER}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
volumes:
- pg_data:/var/lib/postgresql/data
- ./config/jwt:/var/www/html/config/jwt:ro
extra_hosts:
- "host.docker.internal:host-gateway"
restart: unless-stopped
volumes:
pg_data:
uploads_data: