From c7de16b14c487d91783911bfb91eb7b9f3af85cf Mon Sep 17 00:00:00 2001 From: Noah Masur <7386960+nmasur@users.noreply.github.com> Date: Sat, 29 Jun 2024 01:22:59 +0000 Subject: [PATCH] add prom scraping to victoriametrics allows us to not run vmagent when running victoriametrics --- modules/nixos/services/victoriametrics.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/modules/nixos/services/victoriametrics.nix b/modules/nixos/services/victoriametrics.nix index 5b84994..e6dcf19 100644 --- a/modules/nixos/services/victoriametrics.nix +++ b/modules/nixos/services/victoriametrics.nix @@ -38,6 +38,10 @@ in config = { + services.victoriametrics.extraOptions = [ + "-promscrape.config=${(pkgs.formats.yaml { }).generate "scrape.yml" prometheusConfig}" + ]; + systemd.services.vmauth = lib.mkIf config.services.victoriametrics.enable { description = "VictoriaMetrics basic auth proxy"; after = [ "network.target" ];