- Unified Dockerfile with thick/thin mode auto-detection - Single docker-compose.yaml with build arguments - Auto-detect logic: thick mode for Oracle 10g/11g, thin mode for 12.1+ - Simplified .env configuration with clear mode selection - Updated admin.py with FORCE_THIN_MODE and INSTANTCLIENTPATH support - Added comprehensive documentation for both deployment modes - Container tested successfully with thick mode for Oracle 11g compatibility 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
37 lines
1.0 KiB
YAML
37 lines
1.0 KiB
YAML
# UNIFIED Docker Compose - AUTO-DETECT Oracle Mode
|
|
#
|
|
# Configurare prin .env:
|
|
# - Oracle 10g/11g: setează INSTANTCLIENTPATH=/opt/oracle/instantclient_23_9
|
|
# - Oracle 12.1+: setează FORCE_THIN_MODE=true (sau elimină INSTANTCLIENTPATH)
|
|
#
|
|
# Build modes:
|
|
# - docker-compose up --build → thick mode (default)
|
|
# - docker-compose up --build --build-arg ORACLE_MODE=thin → thin mode
|
|
|
|
services:
|
|
gomag_admin:
|
|
build:
|
|
context: ./api
|
|
dockerfile: Dockerfile
|
|
args:
|
|
# thick = Oracle 10g/11g/12.1+ (cu Instant Client)
|
|
# thin = Oracle 12.1+ only (fără Instant Client)
|
|
ORACLE_MODE: ${ORACLE_MODE:-thick}
|
|
container_name: gomag-admin
|
|
ports:
|
|
- "5003:5000"
|
|
volumes:
|
|
- ./api:/app
|
|
- ./logs:/app/logs
|
|
env_file:
|
|
- ./api/.env
|
|
restart: unless-stopped
|
|
healthcheck:
|
|
test: ["CMD", "curl", "-f", "http://localhost:5000/health"]
|
|
interval: 30s
|
|
timeout: 10s
|
|
retries: 3
|
|
|
|
networks:
|
|
default:
|
|
driver: bridge |