mirror of
https://github.com/kittywitch/nixfiles.git
synced 2026-02-09 12:29:19 -08:00
Burnout crawlout
This commit is contained in:
parent
fa19a286c5
commit
e193ee5a9f
7 changed files with 10 additions and 275 deletions
|
|
@ -1,39 +0,0 @@
|
|||
{
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
inherit (lib.modules) mkForce;
|
||||
kubeMasterIP = "100.105.14.66";
|
||||
kubeMasterHostname = "ran.gensokyo.zone";
|
||||
kubeMasterAPIServerPort = 6443;
|
||||
in {
|
||||
# packages for administration tasks
|
||||
environment.systemPackages = with pkgs; [
|
||||
kompose
|
||||
kubectl
|
||||
kubernetes
|
||||
];
|
||||
|
||||
networking = {
|
||||
firewall.enable = mkForce false;
|
||||
extraHosts = "${kubeMasterIP} ${kubeMasterHostname}";
|
||||
};
|
||||
|
||||
systemd.services.etcd.preStart = ''${pkgs.writeShellScript "etcd-wait" ''
|
||||
while [ ! -f /var/lib/kubernetes/secrets/etcd.pem ]; do sleep 1; done
|
||||
''}'';
|
||||
|
||||
services.kubernetes = {
|
||||
roles = ["master" "node"];
|
||||
addons.dns.enable = true; # CoreDNS
|
||||
masterAddress = kubeMasterHostname;
|
||||
apiserverAddress = "https://${kubeMasterHostname}:${toString kubeMasterAPIServerPort}";
|
||||
apiserver = {
|
||||
securePort = kubeMasterAPIServerPort;
|
||||
advertiseAddress = kubeMasterIP;
|
||||
extraOpts = "--service-node-port-range=1-65535";
|
||||
allowPrivileged = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -1,18 +0,0 @@
|
|||
_: {
|
||||
boot = {
|
||||
initrd.availableKernelModules = ["virtiofs"];
|
||||
binfmt.registrations."rosetta" = {
|
||||
interpreter = "/run/rosetta/rosetta";
|
||||
fixBinary = true;
|
||||
wrapInterpreterInShell = false;
|
||||
matchCredentials = true;
|
||||
magicOrExtension = ''\x7fELF\x02\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x3e\x00'';
|
||||
mask = ''\xff\xff\xff\xff\xff\xfe\xfe\x00\xff\xff\xff\xff\xff\xff\xff\xff\xfe\xff\xff\xff'';
|
||||
};
|
||||
};
|
||||
|
||||
nix.settings = {
|
||||
extra-platforms = ["x86_64-linux"];
|
||||
extra-sandbox-paths = ["/run/rosetta" "/run/binfmt"];
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue