fix: fix ekman part of botched merge

This commit is contained in:
2025-09-12 14:38:36 +02:00
parent fcd136ed4e
commit eb7b1f8130
23 changed files with 261 additions and 368 deletions

View File

@@ -3,7 +3,9 @@ with lib;
let
cfg = config.features.host;
computeNodes = import ./c0/nodes.nix;
computeNodes =
import ./c0/nodes.nix ++
import ./c1/nodes.nix;
mkSANs = host: [
host.name
@@ -51,24 +53,24 @@ let
time.timeZone = "Europe/Oslo";
# programs.msmtp = {
# enable = false;
# accounts = {
# default = {
# auth = false;
# tls = false;
# tls_starttls = false;
# port = 24;
# from = "rossby@oceanbox.io";
# host = "smtpgw.itpartner.no";
# # user = "utvikling";
# # password = "S0m3rp0m@de#21!";
# };
# };
# defaults = {
# aliases = "/etc/aliases";
# };
# };
programs.msmtp = {
enable = true;
accounts = {
default = {
auth = false;
tls = false;
tls_starttls = false;
port = 24;
from = "ekman@oceanbox.io";
host = "smtpgw.itpartner.no";
# user = "utvikling";
# password = "S0m3rp0m@de#21!";
};
};
defaults = {
aliases = "/etc/aliases";
};
};
environment.etc = {
"aliases" = {
@@ -99,17 +101,13 @@ let
networking = {
domain = mkDefault "cluster.local";
<<<<<<<< HEAD:rossby/default.nix
defaultGateway = mkDefault "172.16.239.1";
========
defaultGateway = mkDefault "10.255.241.1";
>>>>>>>> ekman:ekman/default.nix
nameservers = mkDefault [ "8.8.8.8" ];
search = mkDefault [];
extraHosts = import ./hosts.nix;
firewall.extraCommands = ''
iptables -I INPUT -s 172.16.239.0/24 -j ACCEPT
iptables -I INPUT -s 172.16.240.0/24 -j ACCEPT
iptables -I INPUT -s 10.255.241.0/24 -j ACCEPT
iptables -I INPUT -s 10.255.243.0/24 -j ACCEPT
'';
};
@@ -146,16 +144,8 @@ let
enable = true;
client = true;
mungeKey = ./munge.key;
mungeUid = mkDefault 994; # hack
mungeUid = mkDefault 996; # hack
# pkey = "0x7666";
<<<<<<<< HEAD:rossby/default.nix
controlMachine = "rossby-manage";
mailDomain = "oceanbox.io";
nodeName = [
"c0-[1-16] Sockets=2 CoresPerSocket=64 ThreadsPerCore=1 RealMemory=256000 TmpDisk=500000 State=UNKNOWN"
"rossby-login Sockets=2 CoresPerSocket=64 ThreadsPerCore=1 RealMemory=256000 TmpDisk=500000 State=UNKNOWN"
"rossby-manage Sockets=2 CoresPerSocket=64 ThreadsPerCore=1 RealMemory=256000 TmpDisk=500000 State=UNKNOWN"
========
controlMachine = "ekman-manage";
mailDomain = "oceanbox.io";
nodeName = [
@@ -163,14 +153,13 @@ let
"c1-[1-8] Sockets=1 CoresPerSocket=64 ThreadsPerCore=1 RealMemory=256000 TmpDisk=100000 State=UNKNOWN"
"ekman Sockets=2 CoresPerSocket=64 ThreadsPerCore=2 RealMemory=256000 TmpDisk=500000 State=UNKNOWN"
"ekman-manage Sockets=2 CoresPerSocket=16 ThreadsPerCore=2 RealMemory=92000 TmpDisk=200000 State=UNKNOWN"
>>>>>>>> ekman:ekman/default.nix
];
partitionName = [
"batch Nodes=c0-[1-16] Default=YES MaxTime=INFINITE State=UP"
"rossby Nodes=rossby-login MaxTime=1:00:00 State=UP"
"short Nodes=c0-[1-8] MaxTime=INFINITE State=UP"
"long Nodes=c0-[3-8] MaxTime=INFINITE State=UP"
"stats Nodes=c0-[7-8] MaxTime=INFINITE State=UP"
"batch Nodes=c0-[1-18] Default=YES MaxTime=INFINITE State=UP"
"ekman Nodes=ekman MaxTime=1:00:00 State=UP"
"short Nodes=c1-[1-8] MaxTime=INFINITE State=UP"
"long Nodes=c1-[3-8] MaxTime=INFINITE State=UP"
"stats Nodes=c1-[7-8] MaxTime=INFINITE State=UP"
];
};
};
@@ -207,26 +196,20 @@ let
k8s = {
enable = true;
node.enable = true;
clusterName = "rossby";
clusterName = "ekman";
initca = ./ca;
cidr = "10.10.0.0/16";
cidr = "10.100.0.0/16";
master = {
<<<<<<<< HEAD:rossby/default.nix
name = "rossby-manage";
address = "172.16.239.221";
========
name = "ekman-manage";
address = "10.255.241.99";
>>>>>>>> ekman:ekman/default.nix
# extraSANs = [
# "rossby-manage.oceanbox.io"
# "frontend.oceanbox.io"
# ];
};
ingressNodes = [
"rossby-manage.oceanbox.io"
"rossby.oceanbox.io"
"ekman.oceanbox.io"
];
fileserver = "rossby-login";
fileserver = "fs-work";
charts = {
acme_email = "acme@oceanbox.io";
# grafana_smtp_user = "utvikling";
@@ -251,30 +234,20 @@ let
uid = 0;
gid = 0;
text = ''
172.16.239.210
10.255.241.80
10.255.241.90
'' + builtins.foldl' (a: x: a + "${x.address}\n") "" computeNodes;
};
programs.ssh.knownHosts = {
<<<<<<<< HEAD:rossby/default.nix
rossby-manage = {
hostNames = [
"manage" "manage.compute.local" "rossby-manage.oceanbox.io" "172.16.239.221" "172.16.240.221"
========
ekman-manage = {
hostNames = [
"ekman-manage" "ekman-manage.cluster.local" "frontend.oceanbox.io" "10.255.241.99" "10.255.243.99"
>>>>>>>> ekman:ekman/default.nix
];
publicKeyFile = ./manage/ssh_host_key.pub;
};
rossby-login = {
ekman = {
hostNames = [
<<<<<<<< HEAD:rossby/default.nix
"rossby" "rpssby-login" "rossby-login.compute.local" "rossby.compute.local" "rossby.oceanbox.io" "172.16.239.222" "172.16.240.222"
];
publicKeyFile = ./login/ssh_host_key.pub;
========
"ekman" "ekman.cluster.local" "ekman.oceanbox.io" "10.255.241.100" "10.255.243.100"
];
publicKeyFile = ./logon/ssh_host_key.pub;
@@ -290,29 +263,16 @@ let
"fs-backup" "fs-backup.cluster.local" "10.255.241.80" "10.255.243.80"
];
publicKeyFile = ./fs-backup/ssh_host_key.pub;
>>>>>>>> ekman:ekman/default.nix
};
# fs-work = {
# hostNames = [
# "fs-work" "fs-work.compute.local" "172.16.239.90" "172.16.240.210"
# ];
# publicKeyFile = ./fs-work/ssh_host_key.pub;
# };
} // builtins.foldl' (a: x:
let n = toString x.idx;
in a // {
"${x.name}" = {
hostNames = [
"${x.name}"
<<<<<<<< HEAD:rossby/default.nix
"${x.name}.compute.local"
"172.16.239.${n}"
"172.16.240.${n}"
========
"${x.name}.cluster.local"
"10.255.241.${n}"
"10.255.243.${n}"
>>>>>>>> ekman:ekman/default.nix
];
publicKeyFile = x.pubkey;
};