modules/nixos/monitoring: switch back to separate subdomains
reverts d4343f7ebe
This commit is contained in:
parent
d259ff73c1
commit
3483677fcc
5 changed files with 18 additions and 15 deletions
docs
modules/nixos/monitoring
terraform
|
@ -1,3 +1,3 @@
|
||||||
- [monitoring.nix-community.org/alertmanager](https://monitoring.nix-community.org/alertmanager)
|
- [alertmanager.nix-community.org/](https://alertmanager.nix-community.org/)
|
||||||
- [monitoring.nix-community.org/grafana](https://monitoring.nix-community.org/grafana)
|
- [grafana.nix-community.org/](https://grafana.nix-community.org/)
|
||||||
- [monitoring.nix-community.org/prometheus](https://monitoring.nix-community.org/prometheus)
|
- [prometheus.nix-community.org/](https://prometheus.nix-community.org/)
|
||||||
|
|
|
@ -14,16 +14,19 @@
|
||||||
owner = "nginx";
|
owner = "nginx";
|
||||||
};
|
};
|
||||||
|
|
||||||
services.nginx.virtualHosts."monitoring.nix-community.org" = {
|
services.nginx.virtualHosts."alertmanager.nix-community.org" = {
|
||||||
locations."/".return = "302 https://nix-community.org/monitoring";
|
locations."/" = {
|
||||||
locations."/alertmanager/" = {
|
|
||||||
basicAuthFile = config.age.secrets.nginx-basic-auth-file.path;
|
basicAuthFile = config.age.secrets.nginx-basic-auth-file.path;
|
||||||
proxyPass = "http://localhost:9093/";
|
proxyPass = "http://localhost:9093/";
|
||||||
};
|
};
|
||||||
locations."/grafana/" = {
|
};
|
||||||
|
services.nginx.virtualHosts."grafana.nix-community.org" = {
|
||||||
|
locations."/" = {
|
||||||
proxyPass = "http://localhost:3000/";
|
proxyPass = "http://localhost:3000/";
|
||||||
proxyWebsockets = true;
|
proxyWebsockets = true;
|
||||||
};
|
};
|
||||||
locations."/prometheus/".proxyPass = "http://localhost:9090/";
|
};
|
||||||
|
services.nginx.virtualHosts."prometheus.nix-community.org" = {
|
||||||
|
locations."/".proxyPass = "http://localhost:9090/";
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -32,8 +32,8 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
server = {
|
server = {
|
||||||
root_url = "https://monitoring.nix-community.org/grafana/";
|
root_url = "https://grafana.nix-community.org/";
|
||||||
domain = "monitoring.nix-community.org";
|
domain = "grafana.nix-community.org";
|
||||||
enforce_domain = true;
|
enforce_domain = true;
|
||||||
enable_gzip = true;
|
enable_gzip = true;
|
||||||
};
|
};
|
||||||
|
|
|
@ -12,10 +12,9 @@
|
||||||
services.prometheus = {
|
services.prometheus = {
|
||||||
enable = true;
|
enable = true;
|
||||||
checkConfig = true;
|
checkConfig = true;
|
||||||
webExternalUrl = "https://monitoring.nix-community.org/prometheus/";
|
webExternalUrl = "https://prometheus.nix-community.org/";
|
||||||
extraFlags = [
|
extraFlags = [
|
||||||
"--storage.tsdb.retention.time=30d"
|
"--storage.tsdb.retention.time=30d"
|
||||||
"--web.route-prefix=/"
|
|
||||||
];
|
];
|
||||||
scrapeConfigs = [
|
scrapeConfigs = [
|
||||||
{
|
{
|
||||||
|
@ -46,11 +45,10 @@
|
||||||
|
|
||||||
services.prometheus.alertmanager = {
|
services.prometheus.alertmanager = {
|
||||||
enable = true;
|
enable = true;
|
||||||
webExternalUrl = "https://monitoring.nix-community.org/alertmanager/";
|
webExternalUrl = "https://alertmanager.nix-community.org/";
|
||||||
listenAddress = "[::1]";
|
listenAddress = "[::1]";
|
||||||
extraFlags = [
|
extraFlags = [
|
||||||
"--cluster.listen-address=''"
|
"--cluster.listen-address=''"
|
||||||
"--web.route-prefix=/"
|
|
||||||
];
|
];
|
||||||
configuration = {
|
configuration = {
|
||||||
route = {
|
route = {
|
||||||
|
|
|
@ -38,14 +38,16 @@ locals {
|
||||||
}
|
}
|
||||||
|
|
||||||
cname = {
|
cname = {
|
||||||
|
"alertmanager" = "web02.nix-community.org"
|
||||||
"build-box" = "build01.nix-community.org"
|
"build-box" = "build01.nix-community.org"
|
||||||
"buildbot" = "build03.nix-community.org"
|
"buildbot" = "build03.nix-community.org"
|
||||||
"darwin-build-box" = "darwin01.nix-community.org"
|
"darwin-build-box" = "darwin01.nix-community.org"
|
||||||
"docker" = "zimbatm.docker.scarf.sh" # Used by nix-community/nixpkgs-docker
|
"docker" = "zimbatm.docker.scarf.sh" # Used by nix-community/nixpkgs-docker
|
||||||
|
"grafana" = "web02.nix-community.org"
|
||||||
"hydra" = "build03.nix-community.org"
|
"hydra" = "build03.nix-community.org"
|
||||||
"monitoring" = "web02.nix-community.org"
|
|
||||||
"nixpkgs-update-logs" = "build02.nix-community.org"
|
"nixpkgs-update-logs" = "build02.nix-community.org"
|
||||||
"nur-update" = "build03.nix-community.org"
|
"nur-update" = "build03.nix-community.org"
|
||||||
|
"prometheus" = "web02.nix-community.org"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue