]> rtime.felk.cvut.cz Git - novaboot.git/commitdiff
shell.nix: Add grub2 and dhcp
authorMichal Sojka <michal.sojka@cvut.cz>
Mon, 28 Jun 2021 06:19:34 +0000 (08:19 +0200)
committerMichal Sojka <michal.sojka@cvut.cz>
Mon, 28 Jun 2021 06:28:07 +0000 (08:28 +0200)
This is to allow manual testing of --dhcp-tftp --grub2 functionality.
Currently, I don't have time to fully automate the tests, but this is
how I tested it manually:

1. Create testboot script with the following content:

       #!/usr/bin/env novaboot

       BOOT_METHOD=linux
       load kernel
       load ramdisk

2. Create a bridge interface:

       brctl addbr br0
       ip link set dev br0 up

3. Run:

       ./testboot --dhcp-tftp --grub2 --remote-cmd="sleep inf" --netif=br0

4. Verify that the Qemu VM boots GRUB2:

       sudo qemu-system-x86_64 -boot n -nic bridge,br=br0 -nographic

shell.nix

index e1641fd61dab0749ae249da414ca049b51bb1d6f..0cdacc477f564693ecac8d7138e716e59acfb1b4 100644 (file)
--- a/shell.nix
+++ b/shell.nix
@@ -10,5 +10,7 @@ mkShell {
   buildInputs = with pkgs; [
     syslinux
     cdrkit
+    grub2
+    dhcp
   ];
 }