1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
#! /bin/bash mkdir -p /adei/{src,cfg,tmp,sys,log,mail} while [ ! -f /adei/cfg/.ready ]; do echo "Waiting for ADEI intialization..." sleep 5 done while [ ! -f "$1" ]; do echo "The script $1 is not populated yet. Waiting...." sleep 1 done echo "Running: $@" exec /bin/bash "$@"