Files
gh-christianlouis-docuelevate/docker-compose.yaml
copilot-swe-agent[bot] e518bce922 fix: merge main branch and renumber migration 037→040
Resolve all merge conflicts between our automation feature branch and
current main (v0.163.0, 920 commits ahead).

Conflicts resolved:
- app/api/__init__.py: add automation_router alongside main's new routers
  (classification_rules, qr_auth, sessions, system_reset)
- app/config.py: add main's new settings (dropbox_use_global_credentials,
  factory_reset_on_startup, enable_factory_reset)
- app/models.py: add main's new models (ClassificationRuleModel, UserSession,
  QRLoginChallenge, SharePoint integration type)
- app/utils/settings_service.py: merge automation_hooks_enabled with main's
  new metadata entries
- docs/API.md: merge automation API docs with main's classification rules docs
- docs/ConfigurationGuide.md: add factory reset settings
- tests/conftest.py: import both AutomationHook and new main models

Migration renumbered:
- 037_add_automation_hooks → 040_add_automation_hooks
- down_revision: 039_add_classification_rules (was 036_add_document_translation_fields)
- Chain: 036 → 037 → 038 → 039 → 040 (automation hooks)

For all non-automation files with conflicts, main's version was taken since
our branch did not modify those files (conflicts were from a stale prior merge).

Co-authored-by: christianlouis <361235+christianlouis@users.noreply.github.com>
Agent-Logs-Url: https://github.com/christianlouis/DocuElevate/sessions/cb62f012-3b69-4415-835e-3857ce3e9f45
2026-03-20 23:54:04 +00:00

115 lines
3.1 KiB
YAML

services:
api:
build:
context: .
dockerfile: Dockerfile
# No container_name — allows `docker compose up --scale api=N`
restart: always
# We'll keep the code in /app, but set working_dir to the shared data directory
working_dir: /workdir
# We'll run uvicorn from the container's /app code
command: ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "8000", "--proxy-headers"]
# Environment variables
environment:
- PYTHONPATH=/app
env_file:
- .env
# Expose container's 8000 -> Host's 8000
ports:
- "8000:8000"
depends_on:
- redis
- beat
# Mount the shared working directory for data
volumes:
- /var/docparse/workdir:/workdir
worker:
build:
context: .
dockerfile: Dockerfile
# No container_name — allows `docker compose up --scale worker=N`
restart: always
# same shared working directory
working_dir: /workdir
# Workers process tasks only — no -B flag (Beat runs in the dedicated beat service)
command: ["celery", "-A", "app.celery_worker", "worker", "--loglevel=info", "-Q", "document_processor,default,celery"]
env_file:
- .env
environment:
- PYTHONPATH=/app
depends_on:
- redis
- gotenberg
# Mount the shared directory
volumes:
- /var/docparse/workdir:/workdir
# Dedicated Celery Beat scheduler — exactly one instance must run at all times.
# Beat publishes periodic tasks to the Redis broker; workers pick them up.
# Do NOT scale this service (replicas must stay at 1).
beat:
build:
context: .
dockerfile: Dockerfile
container_name: document_beat
restart: always
working_dir: /workdir
command: ["celery", "-A", "app.celery_worker", "beat", "--loglevel=info"]
env_file:
- .env
environment:
- PYTHONPATH=/app
depends_on:
- redis
volumes:
- /var/docparse/workdir:/workdir
gotenberg:
image: gotenberg/gotenberg:latest
container_name: gotenberg
restart: always
meilisearch:
image: getmeili/meilisearch:latest
container_name: document_meilisearch
restart: always
environment:
- MEILI_NO_ANALYTICS=true
volumes:
- /var/docparse/meilisearch:/meili_data
redis:
image: redis:alpine
container_name: document_redis
restart: always
# Optional: standalone docs server using MkDocs Material (live-reload during development).
# Start with: docker compose --profile docs up docs
# Access at: http://localhost:8001
# Note: The /help route in the main app serves pre-built docs from the Docker image.
# This service is for content authors who want live preview while editing documentation.
docs:
image: squidfunk/mkdocs-material:latest
container_name: docuelevate_docs
restart: "no"
profiles:
- docs
volumes:
- ./docs:/docs/docs
- ./mkdocs.yml:/docs/mkdocs.yml
working_dir: /docs
command: ["serve", "--dev-addr=0.0.0.0:8000", "--config-file=/docs/mkdocs.yml"]
ports:
- "8001:8000"