every hive runs its otel collector, and agents export to it by default
This commit is contained in:
parent
839efd1642
commit
13daf4c7dc
28 changed files with 245 additions and 303 deletions
|
|
@ -233,18 +233,22 @@ let
|
|||
&& e.HIVE_AGENT_NATS_URL == e.HIVE_C0RE_NATS_URL;
|
||||
}
|
||||
{
|
||||
# What agents are handed lands in their builds, so it has to be the same
|
||||
# on every hive: a name, which this hive's resolver answers with the
|
||||
# bridge IP its collector binds. hive-c0re itself keeps the address.
|
||||
name = "the agents' collector address is a swarm-wide name this hive resolves to its bridge";
|
||||
# Agents are handed no address at all: their module defaults to a
|
||||
# literal name, the same on every hive and in every swarm, which this
|
||||
# hive's resolver answers with the bridge IP its collector binds.
|
||||
# hive-c0re itself keeps the address. `HYPERHIVE_OTEL_ENDPOINT` is gone,
|
||||
# and the bridge address next to it is the control that the lookup on
|
||||
# the same attrset finds what is there.
|
||||
name = "the agents' collector address is a fixed name this hive resolves to its bridge";
|
||||
ok =
|
||||
let
|
||||
e = allLocal.systemd.services.hive-c0re.environment;
|
||||
bridge = allLocal.services.hyperhive.network.bridgeIp;
|
||||
in
|
||||
e.HYPERHIVE_OTEL_ENDPOINT == "http://hive-collector.t.local:4318"
|
||||
!(e ? HYPERHIVE_OTEL_ENDPOINT)
|
||||
&& e.OTEL_EXPORTER_OTLP_ENDPOINT == "http://${bridge}:4318"
|
||||
&& lib.elem "/hive-collector.t.local/${bridge}" allLocal.services.dnsmasq.settings.address;
|
||||
&& allLocal.services.hyperhive.otel.collector.host == "hive-collector.hive"
|
||||
&& lib.elem "/hive-collector.hive/${bridge}" allLocal.services.dnsmasq.settings.address;
|
||||
}
|
||||
{
|
||||
# The agents mint against the swarm's IdP, the same endpoint the hive's
|
||||
|
|
|
|||
Loading…
Reference in a new issue