This project supports file-based secrets so you can keep tokens out of vars.env.
Secret files are loaded as environment variables:
- File name = environment variable name
- File content = environment variable value
Example:
secrets/HF_TOKEN
secrets/ANTHROPIC_AUTH_TOKEN
secrets/OPENAI_API_KEY
The runtime loads secrets from:
${SECRETS_DIR}(default:/app/secretsin container,./secretsfor local launchers)/run/secrets(Docker secrets path, container only)
vars.env and existing process environment variables win by default.
- If a variable already has a non-empty value, the secret file is ignored.
- If a variable is missing or empty, the secret file value is used.
- Create secret files:
mkdir -p secrets
printf '%s' 'hf_xxx' > secrets/HF_TOKEN
printf '%s' 'sk-xxx' > secrets/ANTHROPIC_AUTH_TOKEN
chmod 600 secrets/*- Keep sensitive values out of
vars.env(or leave those keys unset). - Start/restart services:
docker compose up -d --buildSecrets loading is enabled in:
run_vllm_agent.sh(container startup)launchers/local_claude.shlaunchers/local_codex.shlaunchers/open_code.sh
Shared loader:
scripts/load_secrets_env.sh
Compose mount:
docker-compose.ymlmounts./secretsto/app/secrets:ro
secrets/*is ignored by git.secrets/README.mdis tracked to document this behavior.