Skip to content

Commit

Permalink
style / organization
Browse files Browse the repository at this point in the history
  • Loading branch information
David Arnold committed Mar 18, 2021
1 parent d8720d9 commit 12cfb76
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions lib/devos/devosSystem.nix
Original file line number Diff line number Diff line change
Expand Up @@ -6,34 +6,38 @@ lib.nixosSystem (args // {
let
moduleList = builtins.attrValues modules;
modpath = "nixos/modules";
cd = "installer/cd-dvd/installation-cd-minimal-new-kernel.nix";

hostConfig = (lib.nixosSystem (args // { modules = moduleList; })).config;

isoConfig = (lib.nixosSystem
(args // {
modules = moduleList ++ [
"${nixos}/${modpath}/${cd}"

"${nixos}/${modpath}/installer/cd-dvd/installation-cd-minimal-new-kernel.nix"

({ config, suites, ... }: {

# avoid unwanted systemd service startups
disabledModules = suites.allProfilesButCore;

nix.registry = lib.mapAttrs (n: v: { flake = v; }) inputs;

isoImage.isoBaseName = "nixos-" + config.networking.hostName;
isoImage.contents = [{
source = self;
target = "/devos/";
}];
nix.registry = lib.mapAttrs (n: v: { flake = v; }) inputs;
isoImage.storeContents = [
self.devShell.${config.nixpkgs.system}
hostConfig.system.build.toplevel
];

# confilcts with networking.wireless which might be slightly
# more useful on a stick
networking.networkmanager.enable = lib.mkForce false;
# confilcts with networking.wireless
networking.wireless.iwd.enable = lib.mkForce false;

# Set up a link-local boostrap network
# See also: https://github.com/NixOS/nixpkgs/issues/75515#issuecomment-571661659
networking.usePredictableInterfaceNames = lib.mkForce true; # so prefix matching works
Expand Down

0 comments on commit 12cfb76

Please sign in to comment.