#!/usr/bin/env bash # # Initial script for UBLinux # This script are launching before starting init from initrd script # Current dir allways must be set to root (/) # All system path must be relative, except initrd dirs ENABLED=yes [[ ${ENABLED} == "yes" ]] || exit 0 DEBUGMODE=no PATH=.:/:/usr/bin:/usr/local/bin:/usr/local/sbin [[ -d /usr/lib/ublinux ]] && { unset ROOTFS; unset CMD_CHROOT; } || { ROOTFS='.'; CMD_CHROOT='chroot . '; } debug_mode "$0" "$@" # Filter not variable sell symbols from param kernel grep -Eiv ".*-.*=.*|.*\..*=.*" ${ROOTFS}/etc/initvars > ${ROOTFS}/etc/initvars