mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-17 10:26:15 +00:00
Use /bin/rm to remove /firstboot*. Otherwise rm -i alias is picked
up and can cause issues on boot with the prompts. Fix the read-only root case with horrible kludge of mounting rw removing the files, then mounting ro. But since that's no more horrible than the kludge of using marker files in /. With this change, NanoBSD configs can safely use /firstboot + growfs to produce minimal images that grow to the size of the card.
This commit is contained in:
parent
1c66ead7d6
commit
d3e4bc1271
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=293115
7
etc/rc
7
etc/rc
@ -131,11 +131,14 @@ done
|
||||
|
||||
# Remove the firstboot sentinel, and reboot if it was requested.
|
||||
if [ -e ${firstboot_sentinel} ]; then
|
||||
rm ${firstboot_sentinel}
|
||||
[ ${root_rw_mount} = "yes" ] || mount -uw /
|
||||
/bin/rm ${firstboot_sentinel}
|
||||
if [ -e ${firstboot_sentinel}-reboot ]; then
|
||||
rm ${firstboot_sentinel}-reboot
|
||||
/bin/rm ${firstboot_sentinel}-reboot
|
||||
[ ${root_rw_mount} = "yes" ] || mount -ur /
|
||||
kill -INT 1
|
||||
fi
|
||||
[ ${root_rw_mount} = "yes" ] || mount -ur /
|
||||
fi
|
||||
|
||||
echo ''
|
||||
|
Loading…
Reference in New Issue
Block a user