PiShrink
PiShrink copied to clipboard
rc.local: get current SD dev from /dev/ and delay a bit to wait for loopback
This request modifies rc.local to:
- Automatically get the current SD block device from /dev/ instead of hardcoding it to mmcblk0, because some board, such as my Odroid C4, name it different (mmcblk1).
- Added a delay for loopback device to be ready. This is necessary when the image to be shrinked is stored on a slow network share.
Tested on my Raspberry Pi 4, Odroid C4, Orange Pi Zero2 and my Buffalo WXL NAS.