mirror of
https://git.feal.no/felixalb/nixos-config.git
synced 2024-12-13 16:31:48 +01:00
21 lines
527 B
Nix
21 lines
527 B
Nix
{ config, pkgs, ... }:
|
|
|
|
{
|
|
environment.systemPackages = [
|
|
pkgs.prometheus-snmp-exporter
|
|
];
|
|
|
|
systemd.services.prometheus-snmp-exporter = {
|
|
enable = true;
|
|
description = "Gather data from SNMP devices and expose them as Prometheus metrics";
|
|
unitConfig = {
|
|
Type = "simple";
|
|
};
|
|
serviceConfig = {
|
|
ExecStart = "${pkgs.prometheus-snmp-exporter}/bin/snmp_exporter --config.file='/var/prometheus/snmp.yml'";
|
|
# TODO: Fix this conf file!
|
|
};
|
|
wantedBy = [ "multi-user.target" ];
|
|
};
|
|
}
|