hosts/astatine: Add stack to monitor zte hypermobile 5g
This commit is contained in:
46
hosts/astatine/prometheus.nix
Normal file
46
hosts/astatine/prometheus.nix
Normal file
@@ -0,0 +1,46 @@
|
||||
{ config, ... }:
|
||||
|
||||
{
|
||||
services.prometheus = {
|
||||
enable = true;
|
||||
enableReload = true;
|
||||
listenAddress = "[::1]";
|
||||
scrapeConfigs = [
|
||||
{
|
||||
job_name = "prometheus";
|
||||
scrape_interval = "20s";
|
||||
scheme = "http";
|
||||
static_configs = [
|
||||
{
|
||||
targets = [
|
||||
"[::1]:9090"
|
||||
];
|
||||
}
|
||||
];
|
||||
}
|
||||
{
|
||||
job_name = "mu5001tool";
|
||||
scrape_interval = "20s";
|
||||
static_configs = [
|
||||
{
|
||||
targets = [
|
||||
"[::1]:9242"
|
||||
];
|
||||
}
|
||||
];
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
services.nginx = {
|
||||
virtualHosts = {
|
||||
"prometheus.astatine.net.clerie.de" = {
|
||||
enableACME = true;
|
||||
forceSSL = true;
|
||||
basicAuthFile = config.sops.secrets.monitoring-htpasswd.path;
|
||||
locations."/".proxyPass = "http://[::1]:9090/";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
}
|
Reference in New Issue
Block a user