docs: document every env var in .env.example + forward in compose
.env.example now lists every env var read by the app, with a comment
explaining the meaning and the default. The previously-missing ones
(from the common/config.py refactor) are added:
- SPARK_EXECUTOR_DATA_DIR
- SPARK_EXECUTOR_JOBS_DIR
- SPARK_EXECUTOR_LOG_LEVEL
docker-compose.yml forwards all of them with sensible container-side
defaults (SPARK_EXECUTOR_DATA_DIR=/app/data, which is the volume
mount point from the host).
Split the env block in compose into two commented sections
('common/config.py knobs' vs 'gunicorn.conf.py knobs') so it's clear
which file each one is consumed by.
The GUNICORN_LOGLEVEL entry is also added (was missing). All other
GUNICORN_* knobs were already documented.
116/116 still pass.
This commit is contained in:
+13
-1
@@ -31,12 +31,24 @@ services:
|
||||
# Stream Python output to stdout/stderr line-by-line (live loguru output).
|
||||
PYTHONUNBUFFERED: "1"
|
||||
|
||||
# --- common/config.py knobs (see .env.example for full docs) ---
|
||||
# Base dir for connections.json, pending_jobs.json, loguru logs/, jobs/.
|
||||
# Defaults to ./data inside the container (mounted from host via volumes below).
|
||||
SPARK_EXECUTOR_DATA_DIR: ${SPARK_EXECUTOR_DATA_DIR:-/app/data}
|
||||
|
||||
# Where generate_job_file writes LLM-generated PySpark code.
|
||||
# Defaults to <SPARK_EXECUTOR_DATA_DIR>/jobs.
|
||||
SPARK_EXECUTOR_JOBS_DIR: ${SPARK_EXECUTOR_JOBS_DIR:-/app/data/jobs}
|
||||
|
||||
# Fallback YARN RM URL used by the REST client when a Connection's
|
||||
# yarn_rm_url is not set or a Job lacks a snapshot. Leave empty if
|
||||
# you always set yarn_rm_url per Connection via save_connection.
|
||||
YARN_RESOURCE_MANAGER_URL: ${YARN_RESOURCE_MANAGER_URL:-}
|
||||
|
||||
# Gunicorn tuning (see gunicorn.conf.py for full list of knobs).
|
||||
# Loguru verbosity for stderr + info file. DEBUG | INFO.
|
||||
SPARK_EXECUTOR_LOG_LEVEL: ${SPARK_EXECUTOR_LOG_LEVEL:-DEBUG}
|
||||
|
||||
# --- gunicorn.conf.py knobs (NOT read by common/config.py) ---
|
||||
# 2 workers is a good default for a small MCP service; raise for
|
||||
# high-concurrency deploys.
|
||||
GUNICORN_WORKERS: ${GUNICORN_WORKERS:-2}
|
||||
|
||||
Reference in New Issue
Block a user