index : mkinitcpio-archiso32 | |
Archlinux32 initcpio scripts used by archiso | gitolite user |
summaryrefslogtreecommitdiff |
author | Christian Hesse <mail@eworm.de> | 2016-05-24 12:02:42 +0200 |
---|---|---|
committer | Gerardo Exequiel Pozzi <vmlinuz386@gmail.com> | 2016-05-24 21:31:37 -0300 |
commit | 4b7f9e4e7dda8b1337a1b41ba5fd43d82c1ef3ca (patch) | |
tree | cc5881151808c0c61deefbaebdab073ac24060e1 | |
parent | d21e9ee733e0492e34af8730406e3a2be86b4002 (diff) |
-rw-r--r-- | hooks/archiso_pxe_nbd | 11 |
diff --git a/hooks/archiso_pxe_nbd b/hooks/archiso_pxe_nbd index d9bc6d8..fdb2c2b 100644 --- a/hooks/archiso_pxe_nbd +++ b/hooks/archiso_pxe_nbd @@ -25,16 +25,19 @@ archiso_pxe_nbd_mount_handler () { done msg ":: Setup NBD from ${archiso_nbd_srv} at /dev/nbd0" - nbd-client ${archiso_nbd_srv} -N ${archiso_nbd_name} /dev/nbd0 - if [[ "${copytoram}" != "n" ]]; then + nbd-client ${archiso_nbd_srv} -N ${archiso_nbd_name} /dev/nbd0 copytoram="y" + else + nbd-client ${archiso_nbd_srv} -N ${archiso_nbd_name} -systemd-mark -persist /dev/nbd0 fi archisodevice=/dev/nbd0 archiso_mount_handler ${newroot} - msg ":: Disconnect NBD from ${archiso_nbd_srv} at /dev/nbd0" - nbd-client -d /dev/nbd0 + if [[ "${copytoram}" == "y" ]]; then + msg ":: Disconnect NBD from ${archiso_nbd_srv} at /dev/nbd0" + nbd-client -d /dev/nbd0 + fi } |