File tree Expand file tree Collapse file tree
prometheus-iperf3-exporter Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -13,26 +13,33 @@ nix flake update
1313```
1414
1515### VM Tests
16- There are some VM tests in ` checks/ ` testing some critical services. You can run them like this:
16+
17+ There are some VM tests in ` checks/ ` testing some critical services. You can run
18+ them like this:
19+
1720``` bash
1821nix build .# checks.x86_64-linux.<check-name>
1922```
2023
21- Note: ` nix flake check ` cannot be used as currently the repo is unformatted (formatter check is inherited from flakelight)
24+ Note: ` nix flake check ` cannot be used as currently the repo is unformatted
25+ (formatter check is inherited from flakelight)
2226
2327### Rolling back
2428
25- Use the ` rollback ` script on any machine provisioned by this repo to revert to a previous version.
29+ Use the ` rollback ` script on any machine provisioned by this repo to revert to a
30+ previous version.
2631
2732### Secrets
2833
29- * Manage secrets
34+ - Manage secrets
35+
3036```
3137 lib/pass.h
3238```
3339
34- * Add new keys in ` secrets/.public-keys `
40+ - Add new keys in ` secrets/.public-keys `
3541
3642### ToDo
37- * give routing tables names that can be read by humans
38- * schedule DSL reconnect
43+
44+ - give routing tables names that can be read by humans
45+ - schedule DSL reconnect
Original file line number Diff line number Diff line change 2323 pkgs . alejandra
2424 pkgs . git
2525 pkgs . colmena
26- # pkgs.prometheus-snmp-exporter
26+ # pkgs.prometheus-snmp-exporter
2727 ] ;
2828 env . DIRENV_LOG_FORMAT = "" ;
2929 } ;
5353 router = { ... } : {
5454 deployment . targetHost = "router.xhain.space" ;
5555 imports = [
56- kea-lease-viewer . nixosModules . default
57- ] ;
56+ kea-lease-viewer . nixosModules . default
57+ ] ;
5858 } ;
5959
6060 files = { ... } : {
Original file line number Diff line number Diff line change 2828 virtualHosts . "files.xhain.space" = {
2929 root = "/media/storage" ;
3030 extraConfig = ''
31- autoindex on;
31+ autoindex on;
3232 '' ;
3333 } ;
3434 } ;
4545 openFirewall = true ;
4646 securityType = "user" ;
4747
48- settings . global = {
48+ settings . global = {
4949 "server string" = "Files" ;
5050 "map to guest" = "Bad User" ;
5151 "passdb backend" = "tdbsam" ;
Original file line number Diff line number Diff line change 114114 hooks-libraries = [
115115 {
116116 library = "${ pkgs . kea } /lib/kea/hooks/libdhcp_lease_cmds.so" ;
117- parameters = { } ;
117+ parameters = { } ;
118118 }
119119 ] ;
120120
184184 keaSocketPath = controlSocket ;
185185 } ;
186186
187- services . nginx . virtualHosts . ${ config . networking . hostName + "." + config . networking . domain } = {
187+ services . nginx . virtualHosts . ${ config . networking . hostName + "." + config . networking . domain } = {
188188 locations . "/leases" = {
189189 recommendedProxySettings = true ;
190190 proxyPass = "http://${ config . services . kea-lease-viewer . listenAddress } :${ toString config . services . kea-lease-viewer . port } /" ;
Original file line number Diff line number Diff line change 2929 before = [ "bind.service" ] ;
3030 wantedBy = [ "bind.service" ] ;
3131 script = ''
32- mkdir -p /var/lib/bind
33- chown named /var/lib/bind
34- ${ concatStrings (
35- map ( zone : ''
36- if [[ ! -f /var/lib/bind/${ zone } zone ]]; then
37- cp "${ templateFile } " "/var/lib/bind/${ zone } zone"
38- fi
39- chmod 0644 "/var/lib/bind/${ zone } zone"
40- chown named "/var/lib/bind/${ zone } zone"
41- '' ) dynamicZones
42- ) }
43- '' ;
32+ mkdir -p /var/lib/bind
33+ chown named /var/lib/bind
34+ ${ concatStrings (
35+ map ( zone : ''
36+ if [[ ! -f /var/lib/bind/${ zone } zone ]]; then
37+ cp "${ templateFile } " "/var/lib/bind/${ zone } zone"
38+ fi
39+ chmod 0644 "/var/lib/bind/${ zone } zone"
40+ chown named "/var/lib/bind/${ zone } zone"
41+ '' ) dynamicZones
42+ ) }
43+ '' ;
4444 serviceConfig = {
4545 Type = "oneshot" ;
4646 User = "root" ;
Original file line number Diff line number Diff line change 11---
2-
32modules :
43 icmp :
54 prober : icmp
@@ -13,7 +12,7 @@ modules:
1312 timeout : 3s
1413 tcp :
1514 query_response :
16- - expect : " ^SSH-2.0-"
15+ - expect : " ^SSH-2.0-"
1716
1817 https :
1918 prober : http
Original file line number Diff line number Diff line change 77 configFile = "${ ./blackbox-exporter.yml } " ;
88 } ;
99
10- services . nginx . virtualHosts . ${ config . networking . hostName + "." + config . networking . domain } = let
11- addr = config . services . prometheus . exporters . blackbox . listenAddress ;
12- port = toString config . services . prometheus . exporters . blackbox . port ;
13- in {
14- locations . "/blackbox-exporter/metrics" . proxyPass = "http://${ addr } :${ port } /metrics" ;
15- locations . "/blackbox-exporter/probe" . proxyPass = "http://${ addr } :${ port } /probe" ;
16- } ;
10+ services . nginx . virtualHosts . ${ config . networking . hostName + "." + config . networking . domain } =
11+ let
12+ addr = config . services . prometheus . exporters . blackbox . listenAddress ;
13+ port = toString config . services . prometheus . exporters . blackbox . port ;
14+ in
15+ {
16+ locations . "/blackbox-exporter/metrics" . proxyPass = "http://${ addr } :${ port } /metrics" ;
17+ locations . "/blackbox-exporter/probe" . proxyPass = "http://${ addr } :${ port } /probe" ;
18+ } ;
1719}
You can’t perform that action at this time.
0 commit comments