{ config, pkgs, ... }: { services.prometheus.exporters.zfs = { enable = true; listenAddress = "localhost"; extraFlags = [ "--collector.dataset-snapshot" ]; }; services.prometheus.scrapeConfigs = [ { job_name = "zfs"; static_configs = [{ targets = [ "localhost:${toString config.services.prometheus.exporters.zfs.port}" ]; }]; } ]; }