diff options
author | Andrew Cady <d@jerkface.net> | 2016-05-01 05:07:10 -0400 |
---|---|---|
committer | Andrew Cady <d@jerkface.net> | 2016-05-01 05:07:10 -0400 |
commit | 4854ffec94f70705dc95c5657e43c5f69c270a1a (patch) | |
tree | cb5f1a83f41fa412fee05a8627b81016d6861daf /src/initrd/grok-block | |
parent | 61c0618cf504bbd4648b3c08b56d7c68e3d8f7bd (diff) |
netbooting, with unique keys, WORKS
Diffstat (limited to 'src/initrd/grok-block')
-rwxr-xr-x | src/initrd/grok-block | 9 |
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. |