mirror of
https://github.com/linuxkit/linuxkit.git
synced 2025-07-27 04:28:20 +00:00
Merge pull request #596 from justincormack/automount-sort
Sort block devices
This commit is contained in:
commit
b951a26a3a
@ -26,7 +26,7 @@ start()
|
|||||||
then
|
then
|
||||||
DEV="sda"
|
DEV="sda"
|
||||||
else
|
else
|
||||||
DEV="$(find /dev -maxdepth 1 -type b ! -name 'loop*' | grep -v '[0-9]$' | sed 's@.*/dev/@@' | head -1 )"
|
DEV="$(find /dev -maxdepth 1 -type b ! -name 'loop*' | grep -v '[0-9]$' | sed 's@.*/dev/@@' | sort | head -1 )"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
[ -z "${DEV}" ] && exit 1
|
[ -z "${DEV}" ] && exit 1
|
||||||
|
Loading…
Reference in New Issue
Block a user