From 1eeccb54a2ca0a2451781c0d528a410dbffae3c2 Mon Sep 17 00:00:00 2001 From: makefu Date: Fri, 19 Jul 2019 16:04:45 +0200 Subject: wolf.r: graphite.shack redirect to graphite:8080 --- krebs/2configs/shack/influx.nix | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 krebs/2configs/shack/influx.nix (limited to 'krebs/2configs/shack/influx.nix') diff --git a/krebs/2configs/shack/influx.nix b/krebs/2configs/shack/influx.nix new file mode 100644 index 00000000..599416c9 --- /dev/null +++ b/krebs/2configs/shack/influx.nix @@ -0,0 +1,18 @@ +let + port = 8086; +in +{ + networking.firewall.allowedTCPPorts = [ port ]; # for legacy applications + services.nginx.virtualHosts."influx.shack" = { + locations."/" = { + proxyPass = "http://localhost:${toString port}/"; + }; + }; + services.influxdb = { + enable = true; + extraConfig = { + bind-address = ":${toString port}"; + http.log-enabled = false; + }; + }; +} -- cgit v1.2.3 From c929afa9f3513eb457aa72762514ccfd3407dcb7 Mon Sep 17 00:00:00 2001 From: makefu Date: Sat, 20 Jul 2019 00:09:47 +0200 Subject: wolf.r: grafana to seperate config --- krebs/2configs/shack/influx.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'krebs/2configs/shack/influx.nix') diff --git a/krebs/2configs/shack/influx.nix b/krebs/2configs/shack/influx.nix index 599416c9..91b4fa9b 100644 --- a/krebs/2configs/shack/influx.nix +++ b/krebs/2configs/shack/influx.nix @@ -1,3 +1,4 @@ +# hostname: influx.shack let port = 8086; in @@ -11,7 +12,7 @@ in services.influxdb = { enable = true; extraConfig = { - bind-address = ":${toString port}"; + http.bind-address = "0.0.0.0:${toString port}"; http.log-enabled = false; }; }; -- cgit v1.2.3 From 86592a723309d45dc09ff90872c0ee4aa7e52dc0 Mon Sep 17 00:00:00 2001 From: makefu Date: Mon, 2 Sep 2019 13:56:34 +0200 Subject: shack/influx: enable collectd receiver --- krebs/2configs/shack/influx.nix | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) (limited to 'krebs/2configs/shack/influx.nix') diff --git a/krebs/2configs/shack/influx.nix b/krebs/2configs/shack/influx.nix index 91b4fa9b..92cb24bf 100644 --- a/krebs/2configs/shack/influx.nix +++ b/krebs/2configs/shack/influx.nix @@ -1,9 +1,12 @@ -# hostname: influx.shack +{pkgs, ... }: # hostname: influx.shack let port = 8086; + collectd-port = 25826; + db = "collectd_db"; in { networking.firewall.allowedTCPPorts = [ port ]; # for legacy applications + networking.firewall.allowedUDPPorts = [ collectd-port ]; services.nginx.virtualHosts."influx.shack" = { locations."/" = { proxyPass = "http://localhost:${toString port}/"; @@ -14,6 +17,17 @@ in extraConfig = { http.bind-address = "0.0.0.0:${toString port}"; http.log-enabled = false; + http.write-tracing = false; + http.suppress-write-log = true; + data.trace-logging-enabled = false; + data.query-log-enabled = false; + monitoring.enabled = false; + collectd = [{ + enabled = true; + typesdb = "${pkgs.collectd}/share/collectd/types.db"; + database = db; + bind-address = ":${toString collectd-port}"; + }]; }; }; } -- cgit v1.2.3