Evenfire is an intelligence layer platform for running LLM agents that take real actions, on your infrastructure
TypeScript
docs: document the platform image-pull credential across the registry guides
Jose Ramirez0c41337045bb
diff --git a/docs/agents/CLERUM_WORKFLOW_RECIPE_GUIDE.md b/docs/agents/CLERUM_WORKFLOW_RECIPE_GUIDE.mdindex 69e4b22f1..b387da6bd 100644--- a/docs/agents/CLERUM_WORKFLOW_RECIPE_GUIDE.md+++ b/docs/agents/CLERUM_WORKFLOW_RECIPE_GUIDE.md@@ -1440,6 +1440,48 @@ Enforced by the WRC reconciler (not CEL, so the rejection arrives as a status coPlus field-level patterns: `metadata.name` DNS-1123 ≤ 63, `workloadRef` DNS-1123 ≤ 63, `port` ∈ [1, 65535], `icon` data URI regex, `defaultPath` regex.+### 11.5 Platform-managed Secret names (S*)++| Code | Rule |+|---|---|+| S1 | No `secretRef` may name a platform-managed Secret. Today that is `evenfire-registry-pull`, the image-pull credential for the evenfire registry. It applies to every reference kind: `workloads[].imagePullSecrets`, `workloads[].envSecret`, snippet secrets, and `oauthClients[]` refs. Rejected with `422`, rule `workflowWorkloadSecretRefReserved` (or the `workflowSnippetSecret…` / `workflowOauthClientSecret…` variant for those kinds). |++**Why you never declare it.** Images on the evenfire registry are private to the+publishing org, so every install is an authenticated pull. The installing+deployment mints its own pull credential from its own registry identity and+writes it as `evenfire-registry-pull` into `mcp-server`, `sandbox-recipes` and+`sandbox-ui`. The reference is then attached for you: control-api writes it onto+the `McpServer` for connectors, and workflow-recipes injects it into the rendered+pod template for recipe workloads. Injection is keyed on the image host matching+the deployment's `CLERUM_REGISTRY_URL`, so it covers evenfire-registry images+only.++The reference has to be injected rather than declared. A recipe-declared Secret+name is classified by the ownership filter (issue #637) and stripped, because the+recipe does not own that Secret. Declaring the name would therefore fail even if+it were allowed, which is why it is rejected outright instead.++Consequences for a recipe author:++- Publishing a private image on the evenfire registry needs **no** credential+ field in the recipe. The entry stays portable.+- `imagePullSecrets` remains available for a **third-party** private registry+ (GHCR, Docker Hub). Name your own Secret there as usual.+- The Secret is deliberately not labelled `clerum.io/shared` or+ `clerum.io/owner-recipe`, so no recipe's `envSecret` can read it. It is a+ pull-only credential and is not reachable as an environment variable.++If a pod on an evenfire-registry image lands in `ImagePullBackOff`, check whether+the reference was attached at all:++```bash+kubectl get pod <pod> -n sandbox-recipes -o jsonpath='{.spec.imagePullSecrets}'+```++Empty on a recipe workload means injection did not fire, which in practice means+control-api and workflow-recipes disagree on `CLERUM_REGISTRY_URL`. Both read the+same `control-api-config` key by default.+---## 12. Common pitfalls@@ -1693,7 +1735,7 @@ Failure modes that surface ONLY at the pod layer (not in WRC status):| Pod-level failure | Likely cause | Where it surfaces ||---|---|---|-| `ImagePullBackOff` / `ErrImagePull` | Image not publicly pullable; missing `imagePullSecrets`; image truly doesn't exist. | Pod events, container `state.waiting.message`. |+| `ImagePullBackOff` / `ErrImagePull` | Image not publicly pullable; missing `imagePullSecrets`; image truly doesn't exist. For an image on the **evenfire registry**, the platform credential was not attached — check `kubectl get pod <p> -o jsonpath='{.spec.imagePullSecrets}'` (§11.5). | Pod events, container `state.waiting.message`. || `CreateContainerConfigError` | A **required** `envSecret` key references a missing Secret or missing key. (Keys marked `optional: true` are skipped at reconcile time — see §4.1.1 — so they never reach this state.) | Pod events: `secret "X" not found` / `couldn't find key K in Secret X`. || `CrashLoopBackOff` | App crashes on startup — usually unresolved env vars, bad config, DB unreachable. | Pod logs. || Stuck in `ContainerCreating` past sandbox setup | CNI plugin failure, missing PVC, fsGroup mismatch, missing mount target. | Pod events. |@@ -1771,7 +1813,7 @@ The image must satisfy all of:| Requirement | Why | How to verify ||---|---|---|-| **Publicly pullable** (no auth). | `imagePullSecrets` defeats portability. | `docker logout && docker pull <image>` from a fresh shell. If it fails with `repository does not exist or may require 'docker login'`, your registry repo is **private**, not nonexistent — Docker Hub creates new repos as private by default. Flip to Public in the repo's *Settings → Visibility* (Docker Hub) or *Package settings → Change visibility* (GHCR). Your push succeeding tells you nothing about visibility. |+| **Publicly pullable** (no auth) **unless it is on the evenfire registry**. | A pull credential the installer has to create by hand defeats portability. Images on the evenfire registry are exempt: the installing deployment provisions its own credential and attaches it automatically (see §11.5), so a private evenfire-registry image stays portable. | `docker logout && docker pull <image>` from a fresh shell. If it fails with `repository does not exist or may require 'docker login'`, your registry repo is **private**, not nonexistent — Docker Hub creates new repos as private by default. For a third-party registry, flip to Public in the repo's *Settings → Visibility* (Docker Hub) or *Package settings → Change visibility* (GHCR). Your push succeeding tells you nothing about visibility. || **Immutable semver tag** (`1.0.0`, not `:latest` / `:dev`). | `latest` floats; installers can't reproduce builds; K8s won't re-pull on restart without `imagePullPolicy: Always` (which slows every restart). | `docker buildx imagetools inspect <image>` shows a content digest. || **Multi-arch: `linux/amd64` + `linux/arm64`.** | Prod clusters amd64; dev laptops Apple Silicon. Single-arch → `exec format error` on the wrong arch. | `docker buildx imagetools inspect <image>` lists both platforms. || **Non-root.** | All three namespaces (`sandbox-ui`, `sandbox-recipes`, `mcp-server`) enforce PodSecurity baseline; root pods are rejected. UI workloads have additional CSP / sandbox constraints — see §6.4. | `docker run --rm <image> id` → UID ≠ 0. |@@ -1826,7 +1868,7 @@ Before writing `spec.description`, enumerate every Secret reference in your YAML| `webhooks[].verification.secretRef` | HMAC signing secret OR static bearer. | All schemes except `jwt-bearer-jwks`. Webhooks with `optional: true` (§8.6) keep the field but tolerate a missing Secret — the webhook stays dormant (`410 integration_not_configured`) until the Secret is created. || `webhooks[].verification.setupHandshake.secretRef` | Provider verify token (e.g. Meta `hub.verify_token`). | Only with `meta-hub-challenge`. || `workloads[].envSecret` | Env-var-shaped runtime credentials (one Secret, N keys). Keys with `optional: true` (§4.1.1) may be deferred to post-install setup. | Required keys: when the workload needs them. Optional keys: only when the operator wants to enable that integration. |-| `workloads[].imagePullSecrets` | Private-registry pull credentials. | Discouraged for published recipes — document loudly if used. |+| `workloads[].imagePullSecrets` | Pull credentials for a **third-party** private registry (GHCR, Docker Hub). | Discouraged for published recipes — document loudly if used. Do **not** use it for images on the evenfire registry: `evenfire-registry-pull` is a reserved name and declaring it fails the install with `422 workflowWorkloadSecretRefReserved` (§11.5). |For each Secret in the inventory, your description MUST answer these five questions:diff --git a/docs/get-started/registry-quickstart.md b/docs/get-started/registry-quickstart.mdindex a53e1820c..15b6e1069 100644--- a/docs/get-started/registry-quickstart.md+++ b/docs/get-started/registry-quickstart.md@@ -121,6 +121,42 @@ pods they orchestrate:kubectl -n sandbox-recipes get workflowrecipes```+### Private images pull themselves++If the connector or plugin you installed runs a **private** image on the evenfire+registry, you do not create a pull Secret and you do not put credentials in the+entry. On the first install that needs one, control-api mints a pull credential+from your connection's own registry identity and writes it as a Secret named+`evenfire-registry-pull` into all three platform workload namespaces:++```bash+kubectl get secret -A -l clerum.io/managed-by=control-api+# NAMESPACE NAME TYPE DATA+# mcp-server evenfire-registry-pull kubernetes.io/dockerconfigjson 1+# sandbox-recipes evenfire-registry-pull kubernetes.io/dockerconfigjson 1+# sandbox-ui evenfire-registry-pull kubernetes.io/dockerconfigjson 1+```++Then the reference is attached for you. control-api writes it onto the `McpServer`+for connectors, and workflow-recipes injects it into the rendered pod template for+recipe workloads. Recipes never name it themselves. `evenfire-registry-pull` is a+reserved name: declare it in a recipe's `imagePullSecrets` and the install is+rejected, and the admin Secrets API refuses to create, modify or delete it.++Two things follow from this that are worth knowing up front:++- **It is one credential per organization, rotated on each mint.** All three copies+ always hold the same key. That is why control-api writes all three together+ rather than one namespace at a time.+- **It repairs itself.** control-api re-checks the Secret at startup and every 10+ minutes (`REGISTRY_PULL_SECRET_RECONCILE_INTERVAL_MS`), so a copy that was+ deleted or emptied comes back without an install to trigger it.++If you would rather provision the Secret yourself, read the pre-provisioning rules+in [Connect to the registry](../how-to/connect-to-registry.md#api-keys-for-programmatic-publishing)+first. A half-external setup, where you supply some namespaces and leave others to+control-api, is not supported.+## 5. Mint an org API keyThe Control UI publishes using the credential stored at connect time, so@@ -219,22 +255,26 @@ Field-by-field reference and the update/delete routes are in## Troubleshooting-| Symptom | Cause and fix |-| ----------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |-| `control-api` will not start, complains about the URL | `CLERUM_REGISTRY_URL` is not in the allowlist. Add it to `CLERUM_REGISTRY_URL_ALLOWLIST` (see step 1). |-| No Connect panel, no banner | The deployment is in `managed` mode. Managed deployments are connected for you and have nothing to configure. |-| `org_name_taken` on registration | Another deployment holds that organization name. Pick a different one and register again. Nothing was saved. |-| `org_blocklisted` on registration | The name is reserved. Pick a different one. |-| Connect panel stuck at **Finishing the connection** | The inline redeem did not land. Press **Finish connecting**; it needs no token. Reach for **Start over** only when the panel says the credentials were issued but never stored. |-| `deployment_suspended` | Evenfire suspended the deployment. Contact support. Do **not** press Start over: a suspension is reversible, a destroyed keypair is not. |-| `409 CONFLICT` on publish | That `name` + `version` already exists. Bump the version; versions are immutable. |-| `400 scope_required` on publish | The entry name is unscoped. Use `@<org>/<name>`. |-| `invalid reference format` from `docker` | The `@` scope prefix is in the image path. It belongs in the entry name only: push to `registry.evenfire.ai/<org>/<name>`, not `/@<org>/<name>`. |-| `docker push` denied, credential is good | Three quiet causes, likeliest first: a malformed repo path (the scope is dropped, not rejected), a key without `registry:publish`, or the self-hosted quota (10 repos / 2 GiB / 200 versions). |-| `403 selfhosted_public_disabled` | An open-registration org cannot make an image repo public. Images stay private to your org; cross-org sharing needs a grant Evenfire issues. |-| `422` naming the `imageRef` | The image repo path does not equal the entry name. `@acme/db-tools` needs `registry.evenfire.ai/acme/db-tools`. Checked at publish and install, since a mismatch denies the pull. |-| `403` when managing **grants** | Expected. Deployments that onboarded through self-hosted connect do not hold `registry:grant`. Receiving and installing granted plugins still works. |-| Connector installed but cannot reach its API | Egress. Default-deny networking blocks anything not declared in the install's egress step. |+| Symptom | Cause and fix |+| ----------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |+| `control-api` will not start, complains about the URL | `CLERUM_REGISTRY_URL` is not in the allowlist. Add it to `CLERUM_REGISTRY_URL_ALLOWLIST` (see step 1). |+| No Connect panel, no banner | The deployment is in `managed` mode. Managed deployments are connected for you and have nothing to configure. |+| `org_name_taken` on registration | Another deployment holds that organization name. Pick a different one and register again. Nothing was saved. |+| `org_blocklisted` on registration | The name is reserved. Pick a different one. |+| Connect panel stuck at **Finishing the connection** | The inline redeem did not land. Press **Finish connecting**; it needs no token. Reach for **Start over** only when the panel says the credentials were issued but never stored. |+| `deployment_suspended` | Evenfire suspended the deployment. Contact support. Do **not** press Start over: a suspension is reversible, a destroyed keypair is not. |+| `409 CONFLICT` on publish | That `name` + `version` already exists. Bump the version; versions are immutable. |+| `400 scope_required` on publish | The entry name is unscoped. Use `@<org>/<name>`. |+| `invalid reference format` from `docker` | The `@` scope prefix is in the image path. It belongs in the entry name only: push to `registry.evenfire.ai/<org>/<name>`, not `/@<org>/<name>`. |+| `docker push` denied, credential is good | Three quiet causes, likeliest first: a malformed repo path (the scope is dropped, not rejected), a key without `registry:publish`, or the self-hosted quota (10 repos / 2 GiB / 200 versions). |+| `403 selfhosted_public_disabled` | An open-registration org cannot make an image repo public. Images stay private to your org; cross-org sharing needs a grant Evenfire issues. |+| `422` naming the `imageRef` | The image repo path does not equal the entry name. `@acme/db-tools` needs `registry.evenfire.ai/acme/db-tools`. Checked at publish and install, since a mismatch denies the pull. |+| `403` when managing **grants** | Expected. Deployments that onboarded through self-hosted connect do not hold `registry:grant`. Receiving and installing granted plugins still works. |+| Connector installed but cannot reach its API | Egress. Default-deny networking blocks anything not declared in the install's egress step. |+| `409 foreign_secret_would_be_revoked` on install | You pre-provisioned `evenfire-registry-pull` in some platform namespaces but not all three. The pull key is one per org and rotate-on-call, so control-api will not mint and revoke your copy. Supply all three namespaces, or delete yours and let control-api manage them. |+| `409 foreign_secret_unusable` on install | An `evenfire-registry-pull` Secret you own sits in the namespace this install targets, and it cannot serve a pull: wrong `type`, or a `.dockerconfigjson` with no entry for your registry host or an entry carrying no credential. Fix it in place or delete it. Nothing was created; the install fails before the CRD is written. |+| `422 workflowWorkloadSecretRefReserved` on install | The recipe declares `evenfire-registry-pull` in `imagePullSecrets`. Remove it. The platform attaches the reference itself, after the ownership filter that would otherwise strip a declared name. |+| `ImagePullBackOff` on a private evenfire image | Check the pod actually got the reference (`kubectl get pod <p> -o jsonpath='{.spec.imagePullSecrets}'`). If it is empty on a recipe workload, `CLERUM_REGISTRY_URL` differs between control-api and workflow-recipes: injection keys off the image host matching that URL. Both read the same `control-api-config` key by default. |## Next stepsdiff --git a/docs/how-to/connect-to-registry.md b/docs/how-to/connect-to-registry.mdindex c9c676737..435da8910 100644--- a/docs/how-to/connect-to-registry.md+++ b/docs/how-to/connect-to-registry.md@@ -79,12 +79,20 @@ is needed for those.> three namespaces, or delete your copies and let control-api manage all three — a> half-external setup is not supported.>-> A **malformed** external copy is treated differently: one with the wrong `type`, or a-> `.dockerconfigjson` carrying no entry for your registry host, can never serve a pull,-> so it does not hold control-api back from minting for the other namespaces. It does-> fail any install that lands a workload in _its own_ namespace, with-> `foreign_secret_unusable` — fix that Secret in place, or delete it and let control-api-> manage that namespace.+> A **malformed** external copy is treated differently. One with the wrong `type`, or a+> `.dockerconfigjson` that carries no usable credential for your registry host, can never+> serve a pull, so it does not hold control-api back from minting for the other+> namespaces. "No usable credential" covers two cases: no entry for the host at all, and+> an entry that is present but empty. `{"auths":{"registry.evenfire.ai":{}}}` parses fine+> and matches the host, yet the kubelet finds nothing to send and pulls anonymously. An+> entry has to carry at least one non-empty `auth`, `password`, `identitytoken` or+> `registrytoken`. A malformed copy does fail any install that lands a workload in _its+> own_ namespace, with `foreign_secret_unusable`. Fix that Secret in place, or delete it+> and let control-api manage that namespace.+>+> This is a shape check, not a validity check. A well-formed copy is accepted even if its+> key has since been revoked at the registry. Proving otherwise would cost a registry+> round trip on every install.**Creating and managing API keys** (`efrk_` org keys, used for CI and otherprogrammatic publishing) needs registry authentication active. In self-hosted,diff --git a/docs/how-to/publish-plugin-to-registry.md b/docs/how-to/publish-plugin-to-registry.mdindex 632e29a9e..38ad35883 100644--- a/docs/how-to/publish-plugin-to-registry.md+++ b/docs/how-to/publish-plugin-to-registry.md@@ -184,6 +184,25 @@ So your images install cleanly into your own clusters. Sharing one with anotherorganization currently needs Evenfire to issue the grant. Plan around thatbefore you build a distribution story on top of a self-hosted push.+**Private is the normal case, and you do not ship credentials for it.** Because+your images stay private to your org, every install of your entry is an+authenticated pull. You do not put a pull Secret in the recipe, and you do not+ask installers to create one. On the first install that needs it, the installing+deployment mints its own pull credential from its own registry identity and+attaches it to the workloads. Your entry stays credential-free and portable+across the clusters your org runs.++Two rules follow for anything you publish:++- **Never declare `evenfire-registry-pull` in a workload's `imagePullSecrets`.**+ The name is reserved. An entry that declares it is rejected at install with+ `422 workflowWorkloadSecretRefReserved`. The platform attaches the reference+ after the filter that would otherwise strip a recipe-declared Secret name.+- **`imagePullSecrets` is still yours to use for a third-party registry.** If a+ workload pulls from GHCR or Docker Hub, name your own Secret there as before.+ The automatic credential covers images on the evenfire registry only, matched+ by image host.+## 3. Publish — `POST /api/v1/entries`## Step 2 — Write your recipe