10 cfg = config.services.prometheus.exporters.apcupsd;
11 inherit (lib) mkOption types concatStringsSep;
16 apcupsdAddress = mkOption {
20 Address of the apcupsd Network Information Server (NIS).
24 apcupsdNetwork = mkOption {
32 Network of the apcupsd Network Information Server (NIS): one of "tcp", "tcp4", or "tcp6".
39 ${pkgs.prometheus-apcupsd-exporter}/bin/apcupsd_exporter \
40 -telemetry.addr ${cfg.listenAddress}:${toString cfg.port} \
41 -apcupsd.addr ${cfg.apcupsdAddress} \
42 -apcupsd.network ${cfg.apcupsdNetwork} \
43 ${concatStringsSep " \\\n " cfg.extraFlags}