2024-02-05 11:46:52 +01:00
|
|
|
{
|
|
|
|
config,
|
|
|
|
lib,
|
|
|
|
inputs,
|
|
|
|
...
|
|
|
|
}:
|
2024-01-02 22:40:43 +01:00
|
|
|
with lib;
|
|
|
|
let
|
|
|
|
cfg = config.eboskma.pixiecore;
|
|
|
|
|
|
|
|
installerSystem = import ./installer.nix { inherit (inputs.nixpkgs.lib) nixosSystem; };
|
|
|
|
build = installerSystem.config.system.build;
|
|
|
|
in
|
|
|
|
{
|
2024-02-05 11:46:52 +01:00
|
|
|
options.eboskma.pixiecore = {
|
|
|
|
enable = mkEnableOption "pixiecore with NixOS Installer";
|
|
|
|
};
|
2024-01-02 22:40:43 +01:00
|
|
|
|
|
|
|
config = mkIf cfg.enable {
|
|
|
|
services.pixiecore = {
|
|
|
|
enable = true;
|
|
|
|
openFirewall = true;
|
|
|
|
dhcpNoBind = true;
|
|
|
|
|
|
|
|
mode = "boot";
|
|
|
|
kernel = "${build.kernel}/bzImage";
|
|
|
|
initrd = "${build.netbootRamdisk}/initrd";
|
|
|
|
cmdLine = "init=${build.toplevel}/init loglevel=4";
|
|
|
|
debug = true;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|