Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 965d908ac5d8
Choose a base ref
...
head repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: f14628e576d4
Choose a head ref
  • 3 commits
  • 2 files changed
  • 2 contributors

Commits on Aug 8, 2019

  1. Copy the full SHA
    e80b0b2 View commit details
  2. nixos/prometheus-wireguard-exporter: add support for -r switch

    With this switch activated, the exporter also exposes the remote IP of
    each active WireGuard peer.
    Ma27 committed Aug 8, 2019
    Copy the full SHA
    41b9c5f View commit details

Commits on Aug 9, 2019

  1. Merge pull request #66341 from Ma27/bump-prometheus-wireguard-exporter

    prometheus-wireguard-exporter: 3.0.0 -> 3.0.1
    mmahut authored Aug 9, 2019
    Copy the full SHA
    f14628e View commit details
Showing with 11 additions and 2 deletions.
  1. +9 −0 nixos/modules/services/monitoring/prometheus/exporters/wireguard.nix
  2. +2 −2 pkgs/servers/monitoring/prometheus/wireguard-exporter.nix
Original file line number Diff line number Diff line change
@@ -34,6 +34,14 @@ in {
<literal>allowed_ip_1</literal> and so on.
'';
};

withRemoteIp = mkOption {
type = types.bool;
default = false;
description = ''
Whether or not the remote IP of a WireGuard peer should be exposed via prometheus.
'';
};
};
serviceOpts = {
path = [ pkgs.wireguard-tools ];
@@ -45,6 +53,7 @@ in {
-p ${toString cfg.port} \
${optionalString cfg.verbose "-v"} \
${optionalString cfg.singleSubnetPerField "-s"} \
${optionalString cfg.withRemoteIp "-r"} \
${optionalString (cfg.wireguardConfig != null) "-n ${cfg.wireguardConfig}"}
'';
};
4 changes: 2 additions & 2 deletions pkgs/servers/monitoring/prometheus/wireguard-exporter.nix
Original file line number Diff line number Diff line change
@@ -2,13 +2,13 @@

rustPlatform.buildRustPackage rec {
pname = "wireguard-exporter";
version = "3.0.0";
version = "3.0.1";

src = fetchFromGitHub {
owner = "MindFlavor";
repo = "prometheus_wireguard_exporter";
rev = version;
sha256 = "1vgwsg81xcxh7pcdc667mfviwwpzsm4lpllykf78vfahi9qmwffn";
sha256 = "0wfv54ny557mjajjdf0lyq5sbf9m7y50ggm7s2v30c639i0swyrc";
};

cargoSha256 = "06s9194lvwd7lynxnsrjfbjfj87ngvjbqjhx3idf7d1w9mgi4ysw";