loki: Get root user info for microvms from module

This commit is contained in:
Erwin Boskma 2023-11-14 14:46:22 +01:00
parent 5f351fe376
commit 37b9e4585f
Signed by: erwin
SSH key fingerprint: SHA256:9LmFDe1C6jSrEyqxxvX8NtJBmcbB105XoqyUZF092bg

View file

@ -2,7 +2,10 @@
let
mkK3sNode = name: isServer: ipv4Address: ipv6Address: macAddress: {
config = {
imports = [ inputs.sops.nixosModules.sops ];
imports = [
inputs.sops.nixosModules.sops
../../users/root
];
microvm = {
mem = 1024;
@ -41,16 +44,6 @@ let
hypervisor = "cloud-hypervisor";
};
users.users.root = {
initialHashedPassword = "";
openssh.authorizedKeys.keyFiles = [
(pkgs.fetchurl {
url = "https://github.com/eboskma.keys";
sha256 = "uwK4FSLSHiwCJU9U7RBFHIoCmr7uUQLM0JM1u0bi4xo=";
})
];
};
services = {
k3s = {
enable = true;