#!/bin/sh # Initial script for Linux Live Kit # Author: Tomas M export PATH=.:/:/usr/sbin:/usr/bin:/sbin:/bin . /lib/.config . /lib/livekitlib transfer_initramfs MEMORY=/memory CHANGES=$MEMORY/changes UNION=$MEMORY/union DATAMNT=$MEMORY/data BUNDLES=$MEMORY/bundles header "Live Kit init " init_proc_sysfs debug_start debug_shell init_devs init_aufs init_zram # find data dir with filesystem bundles DATA="$(find_data 60 "$DATAMNT")" debug_shell # setup persistent changes, if possible persistent_changes "$DATA" "$CHANGES" debug_shell # copy to RAM if needed DATA="$(copy_to_ram "$DATA" "$CHANGES")" debug_shell # init aufs union init_union "$CHANGES" "$UNION" debug_shell # add data to union union_append_bundles "$DATA" "$BUNDLES" "$UNION" debug_shell # rootcopy copy_rootcopy_content "$DATA" "$UNION" # create empty fstab fstab_create "$UNION" debug_shell header "Live Kit done, starting $LIVEKITNAME" change_root "$UNION" header "!!ERROR occured, you shouldn't be here.!!" /bin/sh