summaryrefslogtreecommitdiff
path: root/src/initrd/grok-block
diff options
context:
space:
mode:
authorAndrew Cady <d@jerkface.net>2016-05-01 05:07:10 -0400
committerAndrew Cady <d@jerkface.net>2016-05-01 05:07:10 -0400
commit4854ffec94f70705dc95c5657e43c5f69c270a1a (patch)
treecb5f1a83f41fa412fee05a8627b81016d6861daf /src/initrd/grok-block
parent61c0618cf504bbd4648b3c08b56d7c68e3d8f7bd (diff)
netbooting, with unique keys, WORKS
Diffstat (limited to 'src/initrd/grok-block')
-rwxr-xr-xsrc/initrd/grok-block9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/initrd/grok-block b/src/initrd/grok-block
index 93770d5..4978a92 100755
--- a/src/initrd/grok-block
+++ b/src/initrd/grok-block
@@ -108,7 +108,14 @@ grok_block()
108 retry_mount $mount_type -o ro "$DEVNAME" "$mountpoint" 108 retry_mount $mount_type -o ro "$DEVNAME" "$mountpoint"
109 fi 109 fi
110 110
111 if mountpoint -q "$mountpoint"; then 111 if [ "$DEVNAME" = /dev/nbd0 ] && mountpoint -q "$mountpoint"; then
112
113 # This is our rootfs, over the network
114 umount "$mountpoint"
115 rmdir "$mountpoint"
116 bootdone samizdat-nbd-dev
117
118 elif mountpoint -q "$mountpoint"; then
112 umount=true 119 umount=true
113 # Device has an unencrypted filesystem on it. 120 # Device has an unencrypted filesystem on it.
114 # So we mount it and look for loop-back overlays. 121 # So we mount it and look for loop-back overlays.