4 DIR="/#SYSCONFDIR#/firststart.d"
5 DIR_OVERLAY_LOWER="/media/rfs/ro"
7 remove_startup_link () {
8 if [ -n "`which update-rc.d`" ]; then
9 update-rc.d -f firststart remove
13 if ! [ -d $DIR ]; then
18 echo "Running first boot tasks...."
22 # check if we have a ro overlay or if we can write changes directly
23 if [ -e "/media/rfs/ro" ]; then
24 # using meta-readonly-rootfs-overlay
25 mount $DIR_OVERLAY_LOWER -o remount,rw
26 rm -r $DIR_OVERLAY_LOWER/$DIR
27 rm $DIR_OVERLAY_LOWER/#SYSCONFDIR#/rc*.d/S*firststart
28 rm $DIR_OVERLAY_LOWER/#SYSCONFDIR#/init.d/firststart
29 mount $DIR_OVERLAY_LOWER -o remount,ro