nixos-config/nixos/machines/pepe/grafana.nix

25 lines
495 B
Nix
Raw Normal View History

2023-02-07 21:56:04 +01:00
{ config, ... }:
{
services.nginx.virtualHosts.${config.services.grafana.domain} = {
extraConfig = ''
allow ${config.tinc.private.subnet};
deny all;
'';
locations."/" = {
proxyPass = "http://localhost:${toString config.services.grafana.port}";
proxyWebsockets = true;
};
};
services.grafana = {
enable = true;
2023-02-10 16:22:00 +01:00
settings.server = {
domain = "grafana.pepe.private";
http_port = 2342;
http_addr = "localhost";
};
2023-02-07 21:56:04 +01:00
};
}