l hilum.r: add isos from /boot/iso

This commit is contained in:
lassulus 2019-10-14 13:38:27 +02:00
parent ea2c783e14
commit ed60af5f44

View File

@ -1,4 +1,4 @@
{ config, ... }: { config, pkgs, ... }:
{ {
imports = [ imports = [
<stockholm/lass> <stockholm/lass>
@ -14,15 +14,19 @@
krebs.build.host = config.krebs.hosts.hilum; krebs.build.host = config.krebs.hosts.hilum;
boot.loader.grub.extraEntries = '' boot.loader.grub = {
menuentry "grml" { extraEntries = ''
iso_path=/isos/grml.iso submenu isos {
export iso_path source /grub/autoiso.cfg
search --set=root --file $iso_path
loopback loop $iso_path
root=(loop)
configfile /boot/grub/loopback.cfg
loopback --delete loop
} }
''; '';
extraFiles."/grub/autoiso.cfg" = (pkgs.stdenv.mkDerivation {
name = "autoiso.cfg";
src = pkgs.grub2.src;
phases = [ "unpackPhase" "installPhase" ];
installPhase = ''
cp docs/autoiso.cfg $out
'';
});
};
} }