tsuki/prometehus: set up slice for exporters

This commit is contained in:
Oystein Kristoffer Tveit 2024-01-23 05:26:22 +01:00
parent 0d3e805611
commit 851d0c1fd0
Signed by: oysteikt
GPG Key ID: 9F2F7D8250F35146
6 changed files with 18 additions and 0 deletions

View File

@ -15,4 +15,6 @@ in {
listenAddress = "127.0.0.1";
};
};
systemd.services.prometheus-nginx-exporter.serviceConfig.Slice = "system-prometheus.slice";
}

View File

@ -15,4 +15,6 @@
enabledCollectors = [ "systemd" ];
};
};
systemd.services.prometheus-node-exporter.serviceConfig.Slice = "system-prometheus.slice";
}

View File

@ -18,4 +18,6 @@
extraFlags = [ "--auto-discover-databases" ];
};
};
systemd.services.prometheus-postgres-exporter.serviceConfig.Slice = "system-prometheus.slice";
}

View File

@ -14,4 +14,6 @@
port = 10394;
};
};
systemd.services.prometheus-redis-exporter.serviceConfig.Slice = "system-prometheus.slice";
}

View File

@ -18,4 +18,6 @@
];
};
};
systemd.services.prometheus-systemd-exporter.serviceConfig.Slice = "system-prometheus.slice";
}

View File

@ -19,4 +19,12 @@
enable = true;
port = 7001;
};
systemd.slices.system-prometheus = {
description = "Prometheus slice";
requires= [ "system.slice" ];
after= [ "system.slice" ];
};
systemd.services.prometheus.serviceConfig.Slice = "system-prometheus.slice";
}