Configuration¶
PyNydus loads only environment variables. There are no config files.
Copy .env.example to .env and fill in your values:
cp .env.example .env
Example .env:
# LLM refinement (both required together, omit both to skip refinement)
NYDUS_LLM_TYPE=openai/gpt-4o
NYDUS_LLM_API_KEY=sk-your-key-here
# Nest registry (required for push/pull and FROM resolution)
# NYDUS_REGISTRY_URL=http://localhost:8000
# NYDUS_REGISTRY_AUTHOR=your-name
# Optional: non-default gitleaks binary (see getting-started/install)
# NYDUS_GITLEAKS_PATH=/path/to/gitleaks
# Optional: PEM text of Ed25519 private key (else ~/.nydus/keys/private.pem)
# NYDUS_PRIVATE_KEY="-----BEGIN PRIVATE KEY-----\n...\n-----END PRIVATE KEY-----\n"
For tests, .env is loaded automatically by pytest-dotenv.
All variables¶
Variable |
Required |
Default |
Purpose |
|---|---|---|---|
|
With |
(none) |
LLM provider/model for refinement (e.g. |
|
With |
(none) |
API key for the LLM provider |
|
For push/pull |
(none) |
Nest registry base URL (e.g. |
|
No |
(none) |
Default author for pushes |
|
No |
|
Gitleaks binary location |
|
No |
File |
When set: PEM body of the Ed25519 private key (not a path). When unset: |
LLM refinement requires both NYDUS_LLM_TYPE and NYDUS_LLM_API_KEY. If
both are unset, refinement is skipped. If only one is set, load_config()
raises ValueError whenever it runs (for example nydus spawn, nydus hatch,
registry commands, or constructing Nydus() in the SDK). Commands that never
call load_config() (such as nydus inspect, env, extract, diff,
delete) do not hit that error. See LLM Refinement.