summaryrefslogtreecommitdiffstats
path: root/builder/dnbd3-rootfs/hooks
diff options
context:
space:
mode:
authortorben2015-11-06 14:56:59 +0100
committertorben2015-11-06 14:56:59 +0100
commitd7af1e5281c71d20cbb87f75ee400c5272c155ba (patch)
tree521f163a5136b7eb102bdfbd525b14bd1810f9db /builder/dnbd3-rootfs/hooks
parentMerge branch 'master' of git.openslx.org:openslx-ng/systemd-init (diff)
downloadsystemd-init-d7af1e5281c71d20cbb87f75ee400c5272c155ba.tar.gz
systemd-init-d7af1e5281c71d20cbb87f75ee400c5272c155ba.tar.xz
systemd-init-d7af1e5281c71d20cbb87f75ee400c5272c155ba.zip
Prepare fstab dynamically in initramfs.
Diffstat (limited to 'builder/dnbd3-rootfs/hooks')
-rwxr-xr-xbuilder/dnbd3-rootfs/hooks/mount/mount-root-device.sh4
1 files changed, 3 insertions, 1 deletions
diff --git a/builder/dnbd3-rootfs/hooks/mount/mount-root-device.sh b/builder/dnbd3-rootfs/hooks/mount/mount-root-device.sh
index e73ae5d6..1f8bc05f 100755
--- a/builder/dnbd3-rootfs/hooks/mount/mount-root-device.sh
+++ b/builder/dnbd3-rootfs/hooks/mount/mount-root-device.sh
@@ -1 +1,3 @@
-mount /dev/mapper/root "$NEWROOT" -o subvol=root
+mount /dev/mapper/root "$NEWROOT" -o subvol=root && \
+# Write fstab for recognized system partition.
+sed --in-place --quiet '/^LABEL=system.*/!s/.*//' /etc/fstab