Skip to content

Commit

Permalink
even more tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
mrtnvgr committed Feb 25, 2024
1 parent 3d86546 commit 77f0166
Showing 1 changed file with 12 additions and 7 deletions.
19 changes: 12 additions & 7 deletions genfmts/isoplus.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
{ config, modulesPath, ... }: {
{ config, lib, modulesPath, ... }:
let
inherit (lib) mkDefault mkIf;
splash = config.boot.loader.grub.splashImage;
in {
imports = [
"${modulesPath}/installer/cd-dvd/iso-image.nix"
"${modulesPath}/profiles/all-hardware.nix"
Expand All @@ -12,13 +16,13 @@
isoImage.appendToMenuLabel = "";

# TODO: Persistent storage
lib.isoFileSystems."/" = {
lib.isoFileSystems."/home" = {
device = "/iso/persistance";
options = [ "loop" ];
};

swapDevices = [ ];
fileSystems = config.lib.isoFileSystems;
# Filesystems
swapDevices = mkDefault [ ];
fileSystems = mkDefault config.lib.isoFileSystems;

# Prevent installation media from evacuating persistent storage, as their
# var directory is not persistent and it would thus result in deletion of
Expand All @@ -29,9 +33,10 @@
'';

# Sync bootloader themes with general settings
# note: sync splashes, if not null
isoImage.grubTheme = config.boot.loader.grub.theme;
isoImage.splashImage = config.boot.loader.grub.splashImage;
isoImage.efiSplashImage = config.boot.loader.grub.splashImage;
isoImage.splashImage = mkIf splash splash;
isoImage.efiSplashImage = mkIf splash splash;

formatAttr = "isoImage";
fileExtension = ".iso";
Expand Down

0 comments on commit 77f0166

Please sign in to comment.