1 { config, lib, pkgs, options, ... }:
4 cfg = config.services.prometheus.exporters.influxdb;
5 inherit (lib) mkOption types concatStringsSep;
10 sampleExpiry = mkOption {
14 description = "How long a sample is valid for";
16 udpBindAddress = mkOption {
19 example = "192.0.2.1:9122";
20 description = "Address on which to listen for udp packets";
25 RuntimeDirectory = "prometheus-influxdb-exporter";
27 ${pkgs.prometheus-influxdb-exporter}/bin/influxdb_exporter \
28 --web.listen-address ${cfg.listenAddress}:${toString cfg.port} \
29 --influxdb.sample-expiry ${cfg.sampleExpiry} ${concatStringsSep " " cfg.extraFlags}