Update auto-resize code to work with any partition number

This commit is contained in:
Michael Tremer
2014-08-24 13:29:18 +02:00
parent c42cbc86b3
commit a24546794d
6 changed files with 62 additions and 48 deletions

View File

@@ -162,11 +162,6 @@ endif
printf "$(FSTAB_FMT)" "$$(blkid -o value -s UUID $(PART_ROOT))" "/" \
"auto" "defaults" 1 1 >> $(MNThdd)/etc/fstab
# Setup symlink for partresize at first boot...
ln -sf ../init.d/partresize $(MNThdd)/etc/rc.d/rcsysinit.d/S25partresize
# Setup symlink for fsresize at second boot...
ln -sf ../init.d/fsresize $(MNThdd)/etc/rc.d/rcsysinit.d/S42fsresize
ifeq "$(BOOTLOADER)" "grub"
ifeq "$(SCON)" "1"
# Enable serial console on GRUB
@@ -189,6 +184,9 @@ endif
--root-directory=$(MNThdd) $(DEVICE)
endif
# Automatically resize the root partition to its maximum size at first boot
touch $(MNThdd)/.partresize
# Unmount
umount $(MNThdd)/proc
umount $(MNThdd)/sys