nixos/tests/prometheus-exporters/influxdb: init
This commit is contained in:
parent
46ea00da23
commit
f77710c6ba
|
@ -273,6 +273,26 @@ let
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
influxdb = {
|
||||||
|
exporterConfig = {
|
||||||
|
enable = true;
|
||||||
|
sampleExpiry = "3s";
|
||||||
|
};
|
||||||
|
exporterTest = ''
|
||||||
|
wait_for_unit("prometheus-influxdb-exporter.service")
|
||||||
|
succeed(
|
||||||
|
"curl -XPOST http://localhost:9122/write --data-binary 'influxdb_exporter,distro=nixos,added_in=21.09 value=1'"
|
||||||
|
)
|
||||||
|
succeed(
|
||||||
|
"curl -sSf http://localhost:9122/metrics | grep 'nixos'"
|
||||||
|
)
|
||||||
|
execute("sleep 5")
|
||||||
|
fail(
|
||||||
|
"curl -sSf http://localhost:9122/metrics | grep 'nixos'"
|
||||||
|
)
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
jitsi = {
|
jitsi = {
|
||||||
exporterConfig = {
|
exporterConfig = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
Loading…
Reference in a new issue