2023-05-16 21:23:04 +00:00
|
|
|
/*
|
|
|
|
|
2023-09-17 19:51:08 +00:00
|
|
|
Name: https://en.wikipedia.org/wiki/KITT
|
|
|
|
Why: Kitt used to have this role before (as well as email and dns)
|
|
|
|
Type: VM
|
|
|
|
Hardware: -
|
|
|
|
From: 2023
|
|
|
|
Role: LDAP Server
|
|
|
|
Notes:
|
2023-05-16 21:23:04 +00:00
|
|
|
*/
|
2023-09-17 19:51:08 +00:00
|
|
|
{
|
2024-05-23 01:10:16 +00:00
|
|
|
config,
|
2023-09-17 19:51:08 +00:00
|
|
|
pkgs,
|
|
|
|
lib,
|
|
|
|
nodes,
|
|
|
|
...
|
|
|
|
}: let
|
2023-05-16 21:23:04 +00:00
|
|
|
# name of the server, sets teh hostname and record for it
|
2023-09-17 19:51:08 +00:00
|
|
|
name = "kitt";
|
|
|
|
ip_pub = "193.1.99.74";
|
|
|
|
hostname = "${name}.skynet.ie";
|
2023-05-19 17:21:33 +00:00
|
|
|
#hostname = ip_pub;
|
2023-05-16 21:23:04 +00:00
|
|
|
in {
|
|
|
|
imports = [
|
2023-08-27 21:47:36 +00:00
|
|
|
../applications/ldap/server.nix
|
2023-08-28 17:01:34 +00:00
|
|
|
../applications/discord.nix
|
2023-11-07 13:38:59 +00:00
|
|
|
../applications/bitwarden/vaultwarden.nix
|
|
|
|
../applications/bitwarden/bitwarden_sync.nix
|
2024-05-23 01:10:16 +00:00
|
|
|
../applications/grafana.nix
|
|
|
|
../applications/prometheus.nix
|
2023-05-16 21:23:04 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
deployment = {
|
|
|
|
targetHost = hostname;
|
|
|
|
targetPort = 22;
|
2023-09-30 22:18:14 +00:00
|
|
|
targetUser = null;
|
2023-06-15 13:30:18 +00:00
|
|
|
|
2023-09-17 19:51:08 +00:00
|
|
|
tags = ["active-core"];
|
2023-05-16 21:23:04 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
# add this server to dns
|
2024-05-30 12:25:52 +00:00
|
|
|
services.skynet.dns.records = [
|
2023-09-17 19:51:08 +00:00
|
|
|
{
|
|
|
|
record = name;
|
|
|
|
r_type = "A";
|
|
|
|
value = ip_pub;
|
|
|
|
server = true;
|
|
|
|
}
|
|
|
|
{
|
|
|
|
record = ip_pub;
|
|
|
|
r_type = "PTR";
|
|
|
|
value = hostname;
|
|
|
|
}
|
2023-07-16 00:53:21 +00:00
|
|
|
];
|
2023-05-16 21:23:04 +00:00
|
|
|
|
2023-07-15 14:05:57 +00:00
|
|
|
services.skynet_backup = {
|
|
|
|
host = {
|
|
|
|
ip = ip_pub;
|
|
|
|
name = name;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2023-05-16 21:23:04 +00:00
|
|
|
services.skynet_ldap = {
|
|
|
|
enable = true;
|
|
|
|
host = {
|
|
|
|
ip = ip_pub;
|
|
|
|
name = name;
|
|
|
|
};
|
|
|
|
};
|
2023-08-28 17:01:34 +00:00
|
|
|
|
|
|
|
services.discord_bot = {
|
|
|
|
enable = true;
|
|
|
|
};
|
2023-11-07 13:38:59 +00:00
|
|
|
|
|
|
|
services.skynet_vaultwarden = {
|
|
|
|
enable = true;
|
|
|
|
|
|
|
|
host = {
|
|
|
|
ip = ip_pub;
|
|
|
|
name = name;
|
|
|
|
};
|
|
|
|
};
|
2024-05-23 01:10:16 +00:00
|
|
|
services.skynet.prometheus = {
|
|
|
|
server = {
|
2024-05-23 03:07:37 +00:00
|
|
|
enable = true;
|
2024-05-23 01:10:16 +00:00
|
|
|
host = {
|
|
|
|
ip = ip_pub;
|
|
|
|
name = name;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
services.skynet.grafana = {
|
|
|
|
enable = true;
|
|
|
|
|
|
|
|
host = {
|
|
|
|
ip = ip_pub;
|
|
|
|
name = name;
|
|
|
|
};
|
|
|
|
};
|
2023-05-16 21:23:04 +00:00
|
|
|
}
|