Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/elenacarino-max/Pildora4_ext_StarWars/llms.txt

Use this file to discover all available pages before exploring further.

MLflow Jedi’s runtime behaviour is controlled entirely through environment variables. At startup, core/config.py calls python-dotenv to load a .env file from the app-v2/ directory, then reads three variables — teacher password, data directory, and maximum team count — falling back to safe defaults if any variable is absent. No code changes are required to adapt the app to a new environment; editing the .env file is sufficient.

Setting up .env

Copy the bundled example file before running the app for the first time. Windows (PowerShell):
Copy-Item .env.example .env
Linux / macOS:
cp .env.example .env
Open the resulting .env file in any text editor and change the values to suit your deployment before starting the application.

Environment variables

The table below summarises all supported variables. Detailed descriptions and usage guidance follow.
VariableTypeDefaultPurpose
MLFLOW_JEDI_TEACHER_PASSWORDstring1234Password for the teacher/Profesorado panel
MLFLOW_JEDI_DATA_DIRstring (path)dataRoot directory for databases and artifacts
MLFLOW_JEDI_MAX_TEAMSinteger10Maximum teams allowed per session

MLFLOW_JEDI_TEACHER_PASSWORD
string
default:"1234"
Password that grants access to the Profesorado (teacher) panel. The panel allows session creation, team monitoring, score management, forced chamber advancement, and JSON/CSV export.
MLFLOW_JEDI_TEACHER_PASSWORD=my-secure-password
The default value 1234 is a placeholder. Always change this before sharing the application URL with anyone outside your own machine. If deployed beyond a trusted local network, add HTTPS and access controls at the infrastructure level as well.
MLFLOW_JEDI_DATA_DIR
string
default:"data"
Path to the directory where MLflow Jedi stores all persistent data: the game database (game.db), the MLflow tracking database (mlflow.db), and the artifacts folder (artifacts/).The compiled default in core/config.py is "data" (a bare relative name). The bundled .env.example ships with ./data, which resolves to the same location — both forms are equivalent because relative paths are resolved from the app-v2/ directory at startup:
# core/config.py (excerpt)
_configured_data_dir = Path(os.getenv("MLFLOW_JEDI_DATA_DIR", "data"))
DATA_DIR = (
    _configured_data_dir if _configured_data_dir.is_absolute()
    else APP_DIR / _configured_data_dir
).resolve()
In Docker: the Dockerfile sets MLFLOW_JEDI_DATA_DIR=/app/data as a build-time ENV instruction, so the container always writes to /app/data regardless of the host .env file — unless you explicitly override it via docker compose environment configuration.
# Absolute path example
MLFLOW_JEDI_DATA_DIR=/var/mlflow-jedi/data

# Relative path example (matches .env.example)
MLFLOW_JEDI_DATA_DIR=./data
MLFLOW_JEDI_MAX_TEAMS
integer
default:"10"
Maximum number of teams that can join a single session. Once the limit is reached, the team selection screen stops offering new slots. The value is cast to int at startup via int(os.getenv("MLFLOW_JEDI_MAX_TEAMS", "10")).
MLFLOW_JEDI_MAX_TEAMS=15
Increase this for larger groups or decrease it for small pilot sessions where you want to keep the teacher panel manageable.

Configuration precedence

Variables are resolved in the following order, from lowest to highest priority:
  1. Compiled defaults — values hard-coded in core/config.py ("1234", "data", "10").
  2. Dockerfile ENV — the Dockerfile overrides MLFLOW_JEDI_DATA_DIR to /app/data for containerised deployments.
  3. .env file — loaded by python-dotenv at startup; overrides both defaults and Dockerfile ENV values when present.
  4. Shell environment — variables already present in the process environment at launch take precedence over the .env file.
In most classroom deployments only the .env file needs to be edited. Docker Compose passes MLFLOW_JEDI_TEACHER_PASSWORD and MLFLOW_JEDI_MAX_TEAMS through from the .env file using the ${VAR:-fallback} syntax defined in docker-compose.yml.

Default .env.example contents

The repository ships with the following example file at app-v2/.env.example:
MLFLOW_JEDI_TEACHER_PASSWORD=1234
MLFLOW_JEDI_DATA_DIR=./data
MLFLOW_JEDI_MAX_TEAMS=10
The .env file is excluded from Git via .gitignore. This prevents accidentally committing credentials or environment-specific paths to the repository. The .env.example file is always committed and serves as the authoritative template.

Build docs developers (and LLMs) love