nixos/machines/vendetta.nix

66 lines
1.2 KiB
Nix
Raw Normal View History

2023-01-25 11:48:44 +00:00
/*
Name: https://masseffect.fandom.com/wiki/Vendetta
Why: Vendetta held troves of important data waiting for folks to request it.
Type: Physical
Hardware: PowerEdge r210
From: 2011 (?)
Role: DNS Server
Notes: Using the server that used to be called Earth
2023-01-25 11:48:44 +00:00
*/
{
pkgs,
lib,
nodes,
...
}: let
2023-01-25 11:48:44 +00:00
# name of the server, sets teh hostname and record for it
name = "vendetta";
ip_pub = "193.1.99.120";
hostname = "${name}.skynet.ie";
host = {
ip = ip_pub;
name = name;
hostname = hostname;
};
2023-01-25 11:48:44 +00:00
in {
imports = [
./hardware/RM002.nix
2023-01-25 11:48:44 +00:00
];
networking.hostName = name;
2023-01-25 11:48:44 +00:00
deployment = {
targetHost = ip_pub;
2023-01-25 11:48:44 +00:00
targetPort = 22;
targetUser = null;
2023-04-20 13:09:36 +00:00
tags = ["active-dns" "dns"];
2023-01-25 11:48:44 +00:00
};
networking = {
# needs to have an address statically assigned
2023-12-22 15:52:34 +00:00
defaultGateway.interface = lib.mkForce "eno1";
2023-12-22 15:52:34 +00:00
interfaces.eno1.ipv4.addresses = [
{
address = "193.1.99.120";
prefixLength = 26;
}
];
2023-01-25 11:48:44 +00:00
};
services.skynet = {
host = host;
backup.enable = true;
dns = {
server = {
enable = true;
# primary dns server (ns1)
primary = true;
ip = ip_pub;
};
};
2023-01-25 11:48:44 +00:00
};
}