diff options
Diffstat (limited to 'ete-k8s.sh')
-rwxr-xr-x | ete-k8s.sh | 12 |
1 files changed, 11 insertions, 1 deletions
@@ -19,7 +19,7 @@ # Please clean up logs when you are done... # if [ "$1" == "" ] || [ "$2" == "" ]; then - echo "Usage: ete-k8s.sh [namespace] [tag]" + echo "Usage: ete-k8s.sh [namespace] [tag] [loadScript]" echo "" echo " List of test case tags (filename for intent: tag)" echo "" @@ -64,6 +64,16 @@ POD=$(kubectl --namespace $NAMESPACE get pods | sed 's/ .*//'| grep robot) TAGS="-i $2" +DIR=$(dirname "$0") +ETESCRIPTDIR=etescripts +ETESCRIPTEXEC=${3:-} + +if [[ "$2" == "ete" ]] && [[ "$ETESCRIPTEXEC" == "loadScript" ]]; then + for script in $(ls -1 "$DIR/$ETESCRIPTDIR"); do + [ -f "$DIR/$ETESCRIPTDIR/$script" ] && [ -x "$DIR/$ETESCRIPTDIR/$script" ] && "$DIR/$ETESCRIPTDIR/$script" + done +fi + ETEHOME=/var/opt/ONAP export GLOBAL_BUILD_NUMBER=$(kubectl --namespace $NAMESPACE exec ${POD} -- bash -c "ls -1q /share/logs/ | wc -l") OUTPUT_FOLDER=$(printf %04d $GLOBAL_BUILD_NUMBER)_ete_$2 |