#!/bin/bash # new header not using prereqs if [ "$1" = "prereqs" ]; then echo "" exit 0 fi # Hooks for install binaries for tcos boot # . /usr/share/initramfs-tools/hook-functions # read conf file => /etc/tcos/initramfs.conf . $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-nfs" ]; then . $CONFDIR/tcos.conf . $TCOS_DIR/tcos-generation-functions.sh for tpl in $(tcos_get_templates); do _verbose "(tcosnfs) 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 # load some hook-addons (not all needed here, we need a minimal image) TCOS_INCLUDE_INIT=1 . ${TCOS_DIR}/hooks-addons/00init . ${TCOS_DIR}/hooks-addons/00main . ${TCOS_DIR}/hooks-addons/00users . ${TCOS_DIR}/hooks-addons/01dhclient . ${TCOS_DIR}/hooks-addons/01busybox . ${TCOS_DIR}/hooks-addons/02hex2ascii . ${TCOS_DIR}/hooks-addons/03udev2 . ${TCOS_DIR}/hooks-addons/03wireless . ${TCOS_DIR}/hooks-addons/23bootchart . ${TCOS_DIR}/hooks-addons/99clean_nfs_image unset TCOS_INCLUDE_INIT manual_add_modules unionfs manual_add_modules aufs manual_add_modules loop fi