Evenfire is an intelligence layer platform for running LLM agents that take real actions, on your infrastructure
TypeScript
docs: update docs for per-Host provider non-secret env
Jose Gabriel Ramirez Encinasabcebc2fbec8
diff --git a/docs/llm-providers/adding-a-provider.md b/docs/llm-providers/adding-a-provider.mdindex 3c5687495..b5434d5b2 100644--- a/docs/llm-providers/adding-a-provider.md+++ b/docs/llm-providers/adding-a-provider.md@@ -186,8 +186,13 @@ refused for it.in `PROVIDER_CREDENTIAL_SLOTS`. The credential-exclusion boundary(`userEnvSnapshot`) derives from the full slot set — never `primarySlot()`.- Non-secret, per-Host config (region, project, endpoint) goes in- `PROVIDER_NON_SECRET_ENV` and flows via the pod env (`host-<ref>-env`), surfaced- in the UI as a "configure in Host → Environment" hint, never a secret field.+ `PROVIDER_NON_SECRET_ENV`, surfaced in the UI as a "configure in Host →+ Environment" hint, never a secret field. It is not in the pod env: mcp-host+ resolves it from the watched per-Host `host-<ref>-env` / `-env-secret` and+ passes the driver a lookup (`ProviderEnvLookup`, `src/llm/providerEnv.ts`)+ limited to the provider's declared names (`process.env` outside a Host pod,+ e.g. dev mode). Read these values through that lookup, never `process.env`+ directly.- **Exclude such providers from `workflowrecipe.yaml`** — the WRC `configure`transport is single-credential and doesn't carry non-secret env, so amulti-credential / endpoint-requiring provider must fail at admission, not@@ -203,7 +208,8 @@ Azure is OpenAI-compatible in shape but not a `baseURL + Bearer` row:- **`model` is the deployment name**, not a catalog id.Its `RUNTIME_FIELDS.azure` carries a `defaultModel` + `tokenizer: 'openai'` but**no static baseURL**, so it takes the explicit `case 'azure':` arm and reads the- endpoint from `process.env` at construction. Fail-closed if the endpoint is absent.+ endpoint from the non-secret env lookup at construction. Fail-closed if the+ endpoint is absent.---diff --git a/mcp-host/README.md b/mcp-host/README.mdindex d556003a0..375906185 100644--- a/mcp-host/README.md+++ b/mcp-host/README.md@@ -41,8 +41,10 @@ the value.Separately, the per-Host `host-<hostRef>-env` ConfigMap and`host-<hostRef>-env-secret` Secret are watched at runtime and feed tool-subprocess env and capability checks, not the startup settings below.-Precedence there is host Secret > host ConfigMap > LLM Secret > process env.+subprocess env, capability checks and the LLM provider's non-secret settings+(`VERTEX_*`, `AWS_REGION`, `AZURE_OPENAI_*`), not the other startup settings+below. Precedence there is host Secret > host ConfigMap > LLM Secret > process+env.#### Core runtime@@ -93,9 +95,9 @@ Precedence there is host Secret > host ConfigMap > LLM Secret > process env.| Variable | Default | Source | Description || --------------------------------------------------- | ------------------------------------------------------------- | -------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- || Provider credential env vars | - | dev | In dev mode, each provider's key is read from its env var (`OPENAI_API_KEY`, `CLAUDE_API_KEY`, `ZAI_API_KEY`, `BAILIAN_API_KEY`, ...; Bedrock needs `AWS_ACCESS_KEY_ID` and `AWS_SECRET_ACCESS_KEY`). In cluster mode keys come from the Secret in `Host.spec.secretRef`. Full list: [Supported LLM Providers](#supported-llm-providers). |-| `VERTEX_PROJECT_ID`, `VERTEX_LOCATION` | `VERTEX_LOCATION`: `us-central1` | - | Non-secret Vertex AI settings, read from the mcp-host process environment. `VERTEX_PROJECT_ID` falls back to the service account's `project_id`. |-| `AWS_REGION` | - | - | Region for Amazon Bedrock (required for Bedrock), read from the process environment. |-| `AZURE_OPENAI_ENDPOINT`, `AZURE_OPENAI_API_VERSION` | - | - | Azure OpenAI resource endpoint (required for Azure; must be `https`) and optional API version, read from the process environment. |+| `VERTEX_PROJECT_ID`, `VERTEX_LOCATION` | `VERTEX_LOCATION`: `us-central1` | - | Non-secret Vertex AI settings. On a Host, set under Host → Environment (per-Host env first, then process env); dev mode reads the process env. `VERTEX_PROJECT_ID` falls back to the service account's `project_id`. |+| `AWS_REGION` | - | - | Region for Amazon Bedrock (required for Bedrock). On a Host, set under Host → Environment (per-Host env first, then process env); dev mode reads the process env. |+| `AZURE_OPENAI_ENDPOINT`, `AZURE_OPENAI_API_VERSION` | - | - | Azure OpenAI resource endpoint (required for Azure; must be `https`) and optional API version. On a Host, set under Host → Environment (per-Host env first, then process env); dev mode reads the process env. || `CLERUM_LLM_ALLOWED_MODELS_CM` | `clerum-llm-allowed-models` | - | Name of the LLM allowlist ConfigMap that control-api writes. A test/canary override only: pointing it at a ConfigMap control-api does not write leaves the Host with no allowed models. || `MCP_HOST_CODEX_SUBSCRIPTION_ENABLED` | `false` | CM `true`; WRC | Allow the `codex-subscription` provider. Only the exact value `true` enables it. See [Use a ChatGPT or Grok subscription](../docs/how-to/connect-llm-subscription.md). || `MCP_HOST_GROK_SUBSCRIPTION_ENABLED` | `false` | HCC (only when the Host is eligible for Grok); WRC | Allow the `grok-subscription` provider. HCC adds it only for Hosts whose Grok projection grants execution, so you do not set it in the ConfigMap. |diff --git a/mcp-host/package-lock.json b/mcp-host/package-lock.jsonindex 8e131b7f2..8424c1378 100644--- a/mcp-host/package-lock.json+++ b/mcp-host/package-lock.json@@ -1,12 +1,12 @@{"name": "clerum-mcp-host",- "version": "0.1.562",+ "version": "0.1.563","lockfileVersion": 3,"requires": true,"packages": {"": {"name": "clerum-mcp-host",- "version": "0.1.562",+ "version": "0.1.563","license": "SEE LICENSE IN LICENSE","dependencies": {"@anthropic-ai/sdk": "^0.32.0",diff --git a/mcp-host/package.json b/mcp-host/package.jsonindex 0226dcd6d..7dc5ae1aa 100644--- a/mcp-host/package.json+++ b/mcp-host/package.json@@ -1,6 +1,6 @@{"name": "clerum-mcp-host",- "version": "0.1.562",+ "version": "0.1.563","description": "MCP Host - reads Host CRD and provides LLM access via OpenAI/Claude","main": "dist/main.js","engines": {