add grafana
This commit is contained in:
parent
0337509664
commit
ec1e45408f
3 changed files with 46 additions and 0 deletions
31
hosts/chunk/grafana.nix
Normal file
31
hosts/chunk/grafana.nix
Normal file
|
@ -0,0 +1,31 @@
|
|||
{config,...}: {
|
||||
services.grafana = {
|
||||
enable = true;
|
||||
settings.server = {
|
||||
http_addr = "127.0.0.1";
|
||||
http_port = 8088;
|
||||
enforce_domain = true;
|
||||
enable_gzip = true;
|
||||
domain = "grafana.cything.io";
|
||||
};
|
||||
settings.analytics.reporting_enabled = false;
|
||||
};
|
||||
|
||||
services.prometheus = {
|
||||
enable = true;
|
||||
exporters = {
|
||||
node = {
|
||||
enable = true;
|
||||
enabledCollectors = [ "systemd" ];
|
||||
};
|
||||
};
|
||||
scrapeConfigs = [
|
||||
{
|
||||
job_name = "chrysalis";
|
||||
static_configs = [{
|
||||
targets = ["127.0.0.1:${toString config.services.prometheus.exporters.node.port}"];
|
||||
}];
|
||||
}
|
||||
];
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue