Compare commits

..

3 Commits

3 changed files with 39 additions and 16 deletions

View File

@ -71,7 +71,7 @@
+ node_memory_active_bytes)
/ node_memory_total_bytes
'';
meta = {
config = {
name_format = "`\${labels.instance} - Memory`";
yaxis = "y";
fill = "tozeroy";
@ -84,7 +84,7 @@
/ ignoring(mode) group_left
sum by (job,instance)(irate(node_cpu_seconds_total[5m]))
'';
meta = {
config = {
name_format = "`\${labels.instance} - \${labels.mode}`";
axis = "y";
};
@ -98,6 +98,7 @@
yaxes = [
{
anchor = "y";
type = "log";
}
];
plots = [
@ -106,7 +107,7 @@
query = ''
stun_attempt_latency_ms
'';
meta = {
config = {
name_format = "`UDP \${labels.domain} latency`";
yaxis = "y";
};
@ -116,8 +117,8 @@
query = ''
ping_latency
'';
meta = {
name_format = "`Ping \${labels.device} latency`";
config = {
name_format = "`Ping \${labels.domain} latency`";
yaxis = "y";
};
}
@ -130,6 +131,7 @@
yaxes = [
{
anchor = "y";
type = "log";
}
];
plots = [
@ -138,7 +140,7 @@
query = ''
irate(node_network_receive_bytes_total{device=~"(lo|en).*"}[5m])
'';
meta = {
config = {
name_format = "`\${labels.device} Rx`";
yaxis = "y";
};
@ -148,7 +150,7 @@
query = ''
irate(node_network_transmit_bytes_total{device=~"(lo|en).*"}[5m])
'';
meta = {
config = {
name_format = "`\${labels.device} Tx`";
yaxis = "y";
};

View File

@ -347,11 +347,11 @@
"rust-overlay": "rust-overlay"
},
"locked": {
"lastModified": 1711068625,
"narHash": "sha256-kNfh3rmFfHKTng6Aun1UZ/atl51XobRjLIeYRJQ6628=",
"lastModified": 1716397295,
"narHash": "sha256-dGJ2TvmOrgenBLvbYQBk9zfx5g+LCG8qdjQWMNF8Hws=",
"owner": "zaphar",
"repo": "Heracles",
"rev": "471d159af752b62f8774d1e4462f2111059583da",
"rev": "ae669767c82965e1db334c178f211fa4c4586df6",
"type": "github"
},
"original": {

View File

@ -126,6 +126,8 @@ with lib;
WatchPaths = [
"/etc/${config.environment.etc."heracles.yaml".target}"
];
StandardOutPath = "/var/log/heracles.log";
StandardErrorPath = "/var/log/heracles.err.log";
KeepAlive = true;
RunAtLoad = true;
};
@ -138,11 +140,9 @@ with lib;
"--listenHost=${config.services.durnitisp.listen}"
];
KeepAlive = {
NetworkState = true;
};
#StandardOutPath = "/var/log/durnitisp.log";
#StandardErrorPath = "var/log/durnitisp.err.log";
KeepAlive = true;
StandardOutPath = "/var/log/durnitisp.log";
StandardErrorPath = "/var/log/durnitisp.err.log";
RunAtLoad = true;
};
};
@ -165,7 +165,28 @@ with lib;
RunAtLoad = true;
};
};
environment.etc."newsyslog.d/org.nixos.prometheus.conf" = mkIf config.services.prometheus.enable {
text = ''
# logfilename [owner:group] mode count size when flags [/pid_file] [sig_num]
${config.launchd.user.agents.prometheus.serviceConfig.StandardOutPath} 644 10 1000 * NJ
${config.launchd.user.agents.prometheus.serviceConfig.StandardErrorPath} 644 10 1000 * NJ
'';
};
environment.etc."newsyslog.d/org.nixos.heracles.conf" = mkIf config.services.prometheus.enable {
text = ''
# logfilename [owner:group] mode count size when flags [/pid_file] [sig_num]
${config.launchd.user.agents.heracles.serviceConfig.StandardOutPath} 644 10 1000 * NJ
${config.launchd.user.agents.heracles.serviceConfig.StandardErrorPath} 644 10 1000 * NJ
'';
};
environment.etc."newsyslog.d/org.nixos.durnitisp.conf" = mkIf config.services.durnitisp.enable {
text = ''
# logfilename [owner:group] mode count size when flags [/pid_file] [sig_num]
${config.launchd.daemons.durnitisp.serviceConfig.StandardOutPath} 644 10 1000 * NJ
${config.launchd.daemons.durnitisp.serviceConfig.StandardErrorPath} 644 10 1000 * NJ
'';
};
};
}