treewide: hypr -> hyprspace

This commit is contained in:
Max Headroom 2023-10-27 20:42:34 +02:00
parent 4e3d88c9b7
commit 9f5d3d819e
7 changed files with 15 additions and 15 deletions

View file

@ -82,14 +82,14 @@
deploy.nodes = with deploy-rs-lib; { deploy.nodes = with deploy-rs-lib; {
TITAN = { TITAN = {
hostname = "titan.hypr"; hostname = "titan.hyprspace";
profiles.system = { profiles.system = {
user = "root"; user = "root";
path = activate.nixos self.nixosConfigurations.TITAN; path = activate.nixos self.nixosConfigurations.TITAN;
}; };
}; };
jericho = { jericho = {
hostname = "jericho.hypr"; hostname = "jericho.hyprspace";
profiles.system = { profiles.system = {
user = "root"; user = "root";
path = activate.nixos self.nixosConfigurations.jericho; path = activate.nixos self.nixosConfigurations.jericho;

View file

@ -4,7 +4,7 @@ tools: {
extraHostNames = clientResolve "titan"; extraHostNames = clientResolve "titan";
}; };
hypr = { hyprspace = {
id = "QmfJ5Tv2z9jFv9Aocevyn6QqRcfm9eYQZhvYvmAVfACfuM"; id = "QmfJ5Tv2z9jFv9Aocevyn6QqRcfm9eYQZhvYvmAVfACfuM";
listenPort = 443; listenPort = 443;
routes = [ routes = [

View file

@ -12,7 +12,7 @@ in with tools.dns; {
publicKey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAICz2nGA+Y4OxhMKsV6vKIns3hOoBkK557712h7FfWXcE"; publicKey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAICz2nGA+Y4OxhMKsV6vKIns3hOoBkK557712h7FfWXcE";
extraHostNames = subResolve "vegas" "backbone"; extraHostNames = subResolve "vegas" "backbone";
}; };
hypr = { hyprspace = {
id = "QmYs4xNBby2fTs8RnzfXEk161KD4mftBfCiR8yXtgGPj4J"; id = "QmYs4xNBby2fTs8RnzfXEk161KD4mftBfCiR8yXtgGPj4J";
routes = [ routes = [
"10.1.0.1/32" "10.1.0.1/32"
@ -25,7 +25,7 @@ in with tools.dns; {
publicKey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIAUG/ubwo68tt2jMP5ia0Sa4mnkWtlKVN5n4Y50U2nTC"; publicKey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIAUG/ubwo68tt2jMP5ia0Sa4mnkWtlKVN5n4Y50U2nTC";
extraHostNames = subResolve "prophet" "node"; extraHostNames = subResolve "prophet" "node";
}; };
hypr = { hyprspace = {
id = "QmbrAHuh4RYcyN9fWePCZMVmQjbaNXtyvrDCWz4VrchbXh"; id = "QmbrAHuh4RYcyN9fWePCZMVmQjbaNXtyvrDCWz4VrchbXh";
routes = [ routes = [
"10.1.0.9/32" "10.1.0.9/32"
@ -37,7 +37,7 @@ in with tools.dns; {
publicKey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINImnMfEzUBU5qiuu05DMPrddTGypOtr+cL1/yQN2GFn"; publicKey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINImnMfEzUBU5qiuu05DMPrddTGypOtr+cL1/yQN2GFn";
extraHostNames = subResolve "checkmate" "node"; extraHostNames = subResolve "checkmate" "node";
}; };
hypr = { hyprspace = {
id = "12D3KooWL84sAtq1QTYwb7gVbhSNX5ZUfVt4kgYKz8pdif1zpGUh"; id = "12D3KooWL84sAtq1QTYwb7gVbhSNX5ZUfVt4kgYKz8pdif1zpGUh";
routes = [ routes = [
"10.1.0.32/32" "10.1.0.32/32"
@ -61,7 +61,7 @@ in with tools.dns; {
publicKey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGV8TbMvGXfAp9R2I9GdR7aLlGjxh2CW1pCZjQSB4TJp"; publicKey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGV8TbMvGXfAp9R2I9GdR7aLlGjxh2CW1pCZjQSB4TJp";
extraHostNames = subResolve "thunderskin" "node"; extraHostNames = subResolve "thunderskin" "node";
}; };
hypr = { hyprspace = {
id = "12D3KooWB9AUPorFoACkWbphyargRBV9osJsYuQDumtQ85j7Aqmg"; id = "12D3KooWB9AUPorFoACkWbphyargRBV9osJsYuQDumtQ85j7Aqmg";
routes = [ routes = [
"10.1.0.4/32" "10.1.0.4/32"
@ -69,7 +69,7 @@ in with tools.dns; {
}; };
}; };
loki = { loki = {
hypr = { hyprspace = {
id = "QmYZ4qA1W9hEZgDKDgKgjNge1ZX3Z25gVGxs34uEoLghgq"; id = "QmYZ4qA1W9hEZgDKDgKgjNge1ZX3Z25gVGxs34uEoLghgq";
routes = [ routes = [
"10.100.3.10/32" # old "10.100.3.10/32" # old

View file

@ -4,7 +4,7 @@ tools: {
extraHostNames = clientResolve "jericho"; extraHostNames = clientResolve "jericho";
}; };
hypr = { hyprspace = {
id = "QmccBLgGP3HR36tTkwSYZX3KDv2EXb1MvYwGVs6PbpbHv9"; id = "QmccBLgGP3HR36tTkwSYZX3KDv2EXb1MvYwGVs6PbpbHv9";
}; };

View file

@ -10,7 +10,7 @@
]; ];
findResolve = list: dnameResolve (append "find" list) ++ append "f.void" list; findResolve = list: dnameResolve (append "find" list) ++ append "f.void" list;
dnameResolve = list: append "private.void" list ++ append "privatevoid.net" list; dnameResolve = list: append "private.void" list ++ append "privatevoid.net" list;
vpnResolve = list: dnameResolve (append "vpn" list) ++ (append "hypr" list); vpnResolve = list: dnameResolve (append "vpn" list) ++ (append "hyprspace" list);
llmnrResolve = append "local"; llmnrResolve = append "local";
append = part: map (x: "${x}.${part}"); append = part: map (x: "${x}.${part}");
portMap = port: map (x: "[${x}]:${builtins.toString port}"); portMap = port: map (x: "[${x}]:${builtins.toString port}");

View file

@ -2,16 +2,16 @@
let let
inherit (config.networking) hostName; inherit (config.networking) hostName;
inherit (inputs.depot.packages.${pkgs.system}) hyprspace; inherit (inputs.depot.packages.${pkgs.system}) hyprspace;
hyprspaceCapableNodes = lib.filterAttrs (_: host: host ? hypr) hosts; hyprspaceCapableNodes = lib.filterAttrs (_: host: host ? hyprspace) hosts;
peersFormatted = builtins.mapAttrs (name: x: { peersFormatted = builtins.mapAttrs (name: x: {
inherit name; inherit name;
inherit (x.hypr) id; inherit (x.hyprspace) id;
routes = map (net: { inherit net; }) (x.hypr.routes or []); routes = map (net: { inherit net; }) (x.hyprspace.routes or []);
}) hyprspaceCapableNodes; }) hyprspaceCapableNodes;
peersFiltered = lib.filterAttrs (name: _: name != hostName) peersFormatted; peersFiltered = lib.filterAttrs (name: _: name != hostName) peersFormatted;
peerList = builtins.attrValues peersFiltered; peerList = builtins.attrValues peersFiltered;
myNode = hosts.${hostName}; myNode = hosts.${hostName};
listenPort = myNode.hypr.listenPort or 8001; listenPort = myNode.hyprspace.listenPort or 8001;
interfaceConfig = pkgs.writeText "hyprspace.json" (builtins.toJSON { interfaceConfig = pkgs.writeText "hyprspace.json" (builtins.toJSON {
listenAddresses = let listenAddresses = let

View file

@ -67,7 +67,7 @@ in {
] ++ ] ++
(lib.optional (config.networking.hostName != "TITAN") (bigBuilder // { (lib.optional (config.networking.hostName != "TITAN") (bigBuilder // {
sshUser = "nix"; sshUser = "nix";
hostName = "titan.hypr"; hostName = "titan.hyprspace";
speedFactor = 12; speedFactor = 12;
maxJobs = 12; maxJobs = 12;
})); }));