mirror of
https://github.com/gensokyo-zone/infrastructure.git
synced 2026-02-09 12:29:19 -08:00
fix(mugetsu): partial netboot install
This commit is contained in:
parent
a4157c1eb3
commit
f0adb4dccc
5 changed files with 152 additions and 20 deletions
39
nixos/hw/c4130.nix
Normal file
39
nixos/hw/c4130.nix
Normal file
|
|
@ -0,0 +1,39 @@
|
|||
{
|
||||
pkgs,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
inherit (lib.modules) mkIf mkMerge mkDefault;
|
||||
in {
|
||||
imports = [
|
||||
./metal.nix
|
||||
];
|
||||
|
||||
boot = {
|
||||
loader = {
|
||||
systemd-boot.enable = mkDefault true;
|
||||
};
|
||||
initrd = {
|
||||
systemd.network = mkIf config.networking.useNetworkd {
|
||||
networks."40-eno1" = {
|
||||
inherit (config.boot.initrd.systemd.network.links.eno1) matchConfig;
|
||||
inherit (config.systemd.network.networks."40-eno1") address gateway DHCP networkConfig linkConfig;
|
||||
};
|
||||
links.eno1 = {
|
||||
matchConfig = {
|
||||
inherit (config.systemd.network.links.eno1.matchConfig) Type MACAddress;
|
||||
};
|
||||
};
|
||||
};
|
||||
availableKernelModules = mkMerge [
|
||||
["ahci" "xhci_pci" "ehci_pci" "usbhid" "usb_storage" "sd_mod" "sr_mod"]
|
||||
(mkIf config.boot.initrd.network.enable ["igb"])
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
environment.systemPackages = [
|
||||
pkgs.ipmitool
|
||||
];
|
||||
}
|
||||
11
nixos/hw/metal.nix
Normal file
11
nixos/hw/metal.nix
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
{
|
||||
pkgs,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
environment.systemPackages = [
|
||||
pkgs.pciutils
|
||||
pkgs.usbutils
|
||||
];
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue