move sdImage import and make rpi DHCP config more generic

This commit is contained in:
oxapentane - 2022-09-10 18:33:49 +02:00
parent be720190f5
commit 525096b6df
Signed by: oxapentane
GPG Key ID: 91FA5E5BF9AA901C
2 changed files with 7 additions and 4 deletions

View File

@ -103,7 +103,6 @@
id = 3;
arch = "aarch64-linux";
extraModules = [
(import "${nixpkgs}/nixos/modules/installer/sd-card/sd-image-aarch64.nix")
./hardware/rpi-3b-4b.nix
./modules/user-stop-box/user.nix
];

View File

@ -1,12 +1,16 @@
{ lib, pkgs, config, ... }:
{ lib, pkgs, config, modulesPath, ... }:
{
imports = [
(modulesPath + "/installer/sd-card/sd-image-aarch64.nix")
];
boot = {
kernelPackages = pkgs.linuxPackages_latest;
supportedFilesystems = lib.mkForce [ "vfat" "ext4" ];
};
networking.useDHCP = false;
networking.interfaces.eth0.useDHCP = true;
networking.useDHCP = lib.mkDefault true;
networking.interfaces.eth0.useDHCP = lib.mkDefault true;
sdImage = lib.mkForce {
populateFirmwareCommands =