egress: let every agent reach the swarm's own endpoints under forward reject
With the egress intercept on, the forward chain rejects what `agent_allow` does not hold, and `agent_allow` only held an agent's ssh connections. An agent whose secret store, queue, logs or metrics endpoint is not on the bridge was refused, so no agent started on a hive away from the swarm host. hive-c0re's egress worker now also renders a `* <ipv4> <port>` line for each endpoint URL it hands to agents (HIVE_AGENT_BAO_ADDR, HIVE_AGENT_LOGS_QUERY_URL, HIVE_AGENT_METRICS_URL, HIVE_AGENT_NATS_URL), resolved like the ssh hosts. `hive-priv egress-pin` expands a `*` line to the MAC of every agent port. An older hive-priv skips the line, as it skips any unknown name. Closes #6902
This commit is contained in:
parent
e77758d0d0
commit
ecfc21b962
1 changed files with 205 additions and 13 deletions
|
|
@ -177,7 +177,9 @@ the agents it has:
|
|||
bridge subnet (`HIVE_NETWORK_SUBNET`) with one warning per host, because a
|
||||
flow to the bridge never reaches the forward chain. It writes
|
||||
`<agent> <ipv4> <port>` lines to `egress.connectionsFile`, beside squid's
|
||||
users file.
|
||||
users file. It adds a `* <ipv4> <port>` line for each endpoint of the swarm
|
||||
itself that agents use (store, queue, logs and metrics), resolved the same
|
||||
way, which `egress-pin` allows to every agent.
|
||||
2. `hive-priv egress-pin` maps each agent to the MAC of its port and fills the
|
||||
`agent_allow` set of the `inet hive_egress` table, in the same transaction
|
||||
as `direct_mac`. `hive-egress-connections.path` runs a pass when the file
|
||||
|
|
|
|||
Loading…
Reference in a new issue