From 9adfdf6ef9ef7784ebeda99e43aeecc5531a5892 Mon Sep 17 00:00:00 2001 From: Dan Jasek Date: Sat, 6 Feb 2016 19:23:29 -0700 Subject: [PATCH] Fix bug in install script lsblk -o label will list the labels of the block devices. Using name only returns /dev/sda, etc. In some cases, labels may be repeated (eg - RAID configurations). It is safer to use greater than 0. --- scripts/installer/lay-down-os | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/installer/lay-down-os b/scripts/installer/lay-down-os index 43ec23b2..f782a173 100755 --- a/scripts/installer/lay-down-os +++ b/scripts/installer/lay-down-os @@ -50,7 +50,7 @@ mount_device() mkdir -p ${BASE_DIR} - if [ "$(lsblk -o name|grep RANCHER_BOOT | wc -l)" -eq "1" ]; then + if [ "$(lsblk -o label|grep RANCHER_BOOT | wc -l)" -gt "0" ]; then label=RANCHER_BOOT fi