mirror of
https://github.com/JuLi0n21/publicConfig.git
synced 2026-04-19 16:00:08 +00:00
32 lines
567 B
Nix
32 lines
567 B
Nix
{ config, pkgs, ... }:
|
|
|
|
{
|
|
environment.systemPackages = with pkgs; [
|
|
k3s
|
|
];
|
|
|
|
environment.sessionVariables = {
|
|
KUBECONFIG = "$HOME/.kube/config";
|
|
};
|
|
|
|
services.k3s = {
|
|
enable = true;
|
|
role = "agent";
|
|
serverAddr = "https://192.168.1.89:6443";
|
|
tokenFile = "/var/lib/rancher/k3s/agent/token";
|
|
};
|
|
|
|
services.openssh = {
|
|
enable = true;
|
|
settings = {
|
|
PasswordAuthentication = false;
|
|
PermitRootLogin = "no";
|
|
};
|
|
};
|
|
|
|
networking.firewall = {
|
|
allowedTCPPorts = [ 10250 22 ];
|
|
allowedUDPPorts = [ 8472 ];
|
|
};
|
|
}
|