derive backend hosts only from the operator's save; the backfill only drops
This commit is contained in:
parent
7e2f4ce7c8
commit
0ad1dad8b5
2 changed files with 229 additions and 108 deletions
|
|
@ -332,18 +332,23 @@ host. It never decrypts TLS, so it holds no signing key. It caches nothing.
|
|||
you add the entry, and `hive-c0re` checks each name again and skips one that
|
||||
fails, or that the base list or the canary covers, or that another entry of
|
||||
the same list covers. A name that resolves to a private address stays a 403.
|
||||
The controller also adds entries itself. When an operator saves an agent's
|
||||
API-key environment, and once when the controller starts, it takes the host
|
||||
from `ANTHROPIC_BASE_URL` and from every variable named `*_BASE_URL`
|
||||
(the address an ACP agent that loads the same file reads), and keeps one
|
||||
The controller also adds entries itself, and only from the operator's save
|
||||
of an agent's API-key environment in the swarm UI: it takes the host from
|
||||
`ANTHROPIC_BASE_URL` and from every variable named `*_BASE_URL` (the
|
||||
address an ACP agent that loads the same file reads), and keeps one
|
||||
`derived` entry for that agent per host. Each host passes the same check as
|
||||
an operator's entry, so an IP address, `localhost` and a base-list name get
|
||||
none. A save or a delete of the environment replaces the agent's derived
|
||||
entries, and destroying the agent drops all its entries. The controller reads only the
|
||||
store's copy: an agent on the hand-placed `backendEnvironmentFile` alone, and
|
||||
the `opencode` preset's `acp.opencode.provider.baseUrl`, get no derived
|
||||
entry, so add one in the swarm UI. A `hive-c0re` that predates the field
|
||||
renders a derived entry like any other.
|
||||
entries, and destroying the agent drops all its entries. The agent can
|
||||
create its own `backend-env` leaf while the leaf is empty, so text found in
|
||||
the store never creates an entry: when the controller starts, it only
|
||||
drops derived entries whose exact host the stored environment no longer
|
||||
names, and logs a host it didn't derive. An environment saved before this
|
||||
existed gets its entries when the operator saves it once more. An agent on
|
||||
the hand-placed `backendEnvironmentFile` alone, and the `opencode` preset's
|
||||
`acp.opencode.provider.baseUrl`, get no derived entry, so add one in the
|
||||
swarm UI. A `hive-c0re` that predates the field renders a derived entry
|
||||
like any other.
|
||||
The swarm's list adds to the hive's `allowedDomains`: `allowedFile` holds
|
||||
those names plus the swarm-wide entries, so removing an entry never removes a
|
||||
name the hive lists itself. Until the controller has a list (it predates the
|
||||
|
|
|
|||
|
|
@ -302,8 +302,10 @@ restarts.
|
|||
A save also keeps the host of `ANTHROPIC_BASE_URL` (and of every `*_BASE_URL`
|
||||
variable) as an automatic allowed-domain entry for the agent, so a restricted
|
||||
agent reaches its provider through the hive's proxy; **Remove** drops it. The
|
||||
controller reads the stored text only. An agent that has just the file gets no
|
||||
entry, and an operator adds its provider's host in the swarm UI (see
|
||||
controller derives only from an operator's save, never from text it finds in the
|
||||
store, so an environment saved before this existed needs one more save. An
|
||||
agent that has just the file gets no entry, and an operator adds its
|
||||
provider's host in the swarm UI (see
|
||||
[allowed domains](../swarm/ui.md#allowed-domains)).
|
||||
|
||||
Provision the file once, out of band (never through nix — an API key in
|
||||
|
|
|
|||
Loading…
Reference in a new issue