From 938c702525b5c53b8742928699452566b5547e24 Mon Sep 17 00:00:00 2001 From: Daniel Poelzleithner Date: Fri, 10 Dec 2021 12:17:54 +0100 Subject: [PATCH] cleanup ssh server when aborting ci run --- tests/ci-run.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/tests/ci-run.sh b/tests/ci-run.sh index 31a1343..6c8d1ab 100755 --- a/tests/ci-run.sh +++ b/tests/ci-run.sh @@ -2,6 +2,15 @@ set -ex +function cleanup() { + echo "** abort. cleanup ssh server" + cd `dirname $BASH_SOURCE`/.. + # CLEANUP=`dirname $BASH_SOURCE`/../teardown.lua + lua tests/teardown.lua +} + +trap cleanup INT EXIT + SRC=`pwd` BUILD_FOLDER=`mktemp -d` echo "Build folder: $BUILD_FOLDER"