2022-12-04 08:53:28 +01:00
|
|
|
{ pkgs, ... }:
|
2021-09-09 18:21:38 +02:00
|
|
|
{
|
|
|
|
c3d2.hq.statistics.enable = true;
|
|
|
|
|
|
|
|
services.collectd.plugins.exec = ''
|
|
|
|
Exec "collectd" "${pkgs.ruby}/bin/ruby" "${./haproxy-stats.rb}"
|
|
|
|
'';
|
|
|
|
|
|
|
|
# add a socket that is world-accessible
|
|
|
|
services.haproxy.config = ''
|
|
|
|
global
|
|
|
|
stats socket /run/haproxy/haproxy-stats.sock mode 666
|
|
|
|
'';
|
|
|
|
}
|