modules/monitoring: clean up tailscale and caddy config
This commit is contained in:
parent
756357552a
commit
9a21ab6621
10 changed files with 109 additions and 47 deletions
|
@ -28,17 +28,21 @@ in
|
|||
)
|
||||
);
|
||||
|
||||
mkCaddyScrapes = mkFunction (
|
||||
mkCaddyScrapes = targets: [
|
||||
{
|
||||
address,
|
||||
port ? 2019,
|
||||
...
|
||||
}:
|
||||
{
|
||||
job_name = "caddy_${address}";
|
||||
static_configs = [ { targets = [ "${address}${mkPort port}" ]; } ];
|
||||
job_name = "caddy";
|
||||
scheme = "https";
|
||||
static_configs = map (
|
||||
{
|
||||
address,
|
||||
port ? 2019,
|
||||
}:
|
||||
{
|
||||
targets = [ "${address}${mkPort port}" ];
|
||||
}
|
||||
) targets;
|
||||
}
|
||||
);
|
||||
];
|
||||
|
||||
mkCaddyRules = mkFunction (
|
||||
{
|
||||
|
@ -63,17 +67,20 @@ in
|
|||
}
|
||||
);
|
||||
|
||||
mkNodeScrapes = mkFunction (
|
||||
mkNodeScrapes = targets: [
|
||||
{
|
||||
address,
|
||||
port ? 9100,
|
||||
...
|
||||
}:
|
||||
{
|
||||
job_name = "node_${address}";
|
||||
static_configs = [ { targets = [ "${address}${mkPort port}" ]; } ];
|
||||
job_name = "node_exporter";
|
||||
static_configs = map (
|
||||
{
|
||||
address,
|
||||
port ? 9100,
|
||||
}:
|
||||
{
|
||||
targets = [ "${address}${mkPort port}" ];
|
||||
}
|
||||
) targets;
|
||||
}
|
||||
);
|
||||
];
|
||||
|
||||
mkNodeRules = mkFunction (
|
||||
{
|
||||
|
|
|
@ -12,5 +12,9 @@
|
|||
grafanaUrl = "https://grafana.xiny.li";
|
||||
synapseUrl = "https://xiny.li";
|
||||
synapseDelegateUrl = "https://synapse.xiny.li";
|
||||
|
||||
prometheusCollectors = [
|
||||
"thorite.coho-tet.ts.net"
|
||||
];
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue