From cc547e7da31bd428a12eb5b3972a617c814483e2 Mon Sep 17 00:00:00 2001 From: Anish Lakhwara Date: Thu, 4 May 2023 23:09:47 +1000 Subject: [PATCH] add k8s config for k3s and minikube to curve --- hosts/curve/default.nix | 1 + hosts/profiles/kuberenetes/default.nix | 13 +++++++++++++ 2 files changed, 14 insertions(+) create mode 100644 hosts/profiles/kuberenetes/default.nix diff --git a/hosts/curve/default.nix b/hosts/curve/default.nix index c55b5ec8..6e906a98 100644 --- a/hosts/curve/default.nix +++ b/hosts/curve/default.nix @@ -13,6 +13,7 @@ ../profiles/mimetypes ../profiles/syncthing ../profiles/mossnet-hosts + ../profiles/kuberenetes ]; # home-manager.users.anish = import ../../home/gui; diff --git a/hosts/profiles/kuberenetes/default.nix b/hosts/profiles/kuberenetes/default.nix new file mode 100644 index 00000000..ceef13ae --- /dev/null +++ b/hosts/profiles/kuberenetes/default.nix @@ -0,0 +1,13 @@ +{ pkgs, ... }: + +{ + # k3s + networking.firewall.allowedTCPPorts = [ 6443 ]; + services.k3s.enable = true; + services.k3s.role = "server"; + # services.k3s.extraFlags = toString [ + # "--kubelet-arg=v=4" # Optionally add additional args to k3s + # ]; + environment.systemPackages = [ pkgs.k3s pkgs.kubernetes-helm ]; + +}