#!/bin/bash # new header not using prereqs if [ "$1" = "prereqs" ]; then echo "" exit 0 fi . /usr/share/initramfs-tools/hook-functions . /usr/share/initramfs-tools/scripts/functions . $CONFDIR/initramfs.conf # read from env vars TCOS_BOOT TCOS_BOOT=$(env| awk -F "=" '/^TCOS_BOOT=/ {print $2}') if [ "${TCOS_BOOT}" != "" ]; then BOOT=$TCOS_BOOT fi if [ "${BOOT}" = "tcos" -o "${BOOT}" = "tcos-nfs" ]; then . $CONFDIR/tcos.conf . $TCOS_DIR/tcos-generation-functions.sh #for tpl in $(tcos_get_templates); do # _verbose "(tcosmain) loading template $(basename $tpl)" # . $tpl #done # load forced settings for derivatives if [ -d $CONFDIR/conf.d/ ]; then for file in $CONFDIR/conf.d/tcos*conf; do [ -e $file ] && . $file done fi # copy scripts into image cp -ra ${TCOS_DIR}/scripts/* ${DESTDIR}/scripts/ run_scripts ${TCOS_DIR}/hooks fi