feat: USB recovery installer ISO (ssh key baked in) for headless reinstall
This commit is contained in:
@@ -60,6 +60,25 @@
|
|||||||
})
|
})
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# Bootable USB recovery installer with our SSH key + sshd + DHCP.
|
||||||
|
# Build the ISO:
|
||||||
|
# nix build .#nixosConfigurations.installer-iso.config.system.build.isoImage
|
||||||
|
# dd it to a USB stick, boot the ZimaBlade from it, SSH in, ./deploy install.
|
||||||
|
installer-iso = nixpkgs.lib.nixosSystem {
|
||||||
|
inherit system;
|
||||||
|
modules = [
|
||||||
|
(nixpkgs + "/nixos/modules/installer/cd-dvd/installation-cd-minimal.nix")
|
||||||
|
({ ... }: {
|
||||||
|
services.openssh.enable = true;
|
||||||
|
services.openssh.settings.PermitRootLogin = "prohibit-password";
|
||||||
|
users.users.root.openssh.authorizedKeys.keys = [
|
||||||
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGZpkPVhzi1zG5JI9hWyUgdyvNIQbp4ts4jw3idpMhhN erik@laptop"
|
||||||
|
];
|
||||||
|
networking.hostName = "jupiter-installer";
|
||||||
|
})
|
||||||
|
];
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user