fix(deploy): wire OCR training token to backend and raise container memory limit

- Pass OCR_TRAINING_TOKEN through to the backend container as
  APP_OCR_TRAINING_TOKEN so RestClientOcrClient sends the X-Training-Token
  header when calling /train and /segtrain.
- Raise mem_limit/memswap_limit from 8g to 12g to give segtrain headroom
  on hosts with more available RAM.
- Uncomment OCR_TRAINING_TOKEN in .env.example — it is now required.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Marcel
2026-04-14 13:07:11 +02:00
committed by marcel
parent a5979c4069
commit f08897b801
2 changed files with 6 additions and 5 deletions

View File

@@ -21,9 +21,9 @@ PORT_FRONTEND=5173
PORT_MAILPIT_UI=8100
PORT_MAILPIT_SMTP=1025
# OCR Training — set a secret token to protect the /train and /segtrain endpoints on the
# Python OCR microservice. Leave empty to disable token authentication (development only).
# OCR_TRAINING_TOKEN=change-me-in-production
# OCR Training — secret token required to call /train and /segtrain on the OCR service.
# Also set in the backend so it can pass the token through. Must not be empty in production.
OCR_TRAINING_TOKEN=change-me-in-production
# Production SMTP — uncomment and fill in to send real emails instead of catching them
# APP_BASE_URL=https://your-domain.example.com