Moved grafana / prometheus to kitt

This commit is contained in:
daragh 2024-05-23 02:10:16 +01:00
parent 1ea703bfa1
commit 9aeb7313b4
No known key found for this signature in database
2 changed files with 26 additions and 26 deletions

View file

@ -9,6 +9,7 @@ Role: LDAP Server
Notes: Notes:
*/ */
{ {
config,
pkgs, pkgs,
lib, lib,
nodes, nodes,
@ -25,6 +26,8 @@ in {
../applications/discord.nix ../applications/discord.nix
../applications/bitwarden/vaultwarden.nix ../applications/bitwarden/vaultwarden.nix
../applications/bitwarden/bitwarden_sync.nix ../applications/bitwarden/bitwarden_sync.nix
../applications/grafana.nix
../applications/prometheus.nix
]; ];
deployment = { deployment = {
@ -77,4 +80,27 @@ in {
name = name; name = name;
}; };
}; };
services.skynet.prometheus = {
server = {
host = {
ip = ip_pub;
name = name;
};
};
};
services.skynet.grafana = {
enable = true;
host = {
ip = ip_pub;
name = name;
};
# maybe just do provision config directly ?
datasource = {
name = "Prometheus";
url = "localhost:${toString config.services.prometheus.port}";
};
};
} }

View file

@ -26,8 +26,6 @@ Notes:
groups_trusted = map (x: "@${x}") groups; groups_trusted = map (x: "@${x}") groups;
in { in {
imports = [ imports = [
../applications/grafana.nix
../applications/prometheus.nix
]; ];
deployment = { deployment = {
@ -52,30 +50,6 @@ in {
sudo_groups = groups; sudo_groups = groups;
}; };
services.skynet.prometheus = {
server = {
host = {
ip = ip_pub;
name = name;
};
};
};
services.skynet.grafana = {
enable = true;
host = {
ip = ip_pub;
name = name;
};
# maybe just do provision config directly ?
datasource = {
name = "Prometheus";
url = "localhost:${toString config.services.prometheus.port}";
};
};
skynet_dns.records = [ skynet_dns.records = [
{ {
record = name; record = name;