core: 兼容 xen 磁盘

This commit is contained in:
bin456789
2023-07-09 00:02:06 +08:00
parent 69f2bd2e58
commit 9efe2552e3
4 changed files with 8 additions and 4 deletions

View File

@@ -8,7 +8,9 @@ cat <<EOF >>/autoinstall.yaml
size: 0
EOF
xda=$(lsblk -dn -o NAME | grep -E 'nvme0n1|.da')
# xda=$(lsblk -dn -o NAME | grep -E 'nvme0n1|.da')
# shellcheck disable=SC2010
xda=$(ls /dev/ | grep -Ex 'sda|hda|xda|vda|xvda|nvme0n1')
# 是用 size 寻找分区number 没什么用
# https://curtin.readthedocs.io/en/latest/topics/storage.html
size_os=$(lsblk -bn -o SIZE /dev/disk/by-label/os)