From e4b1cee36005aca5d8b01fd2986792dc253470c9 Mon Sep 17 00:00:00 2001 From: Tullio Sebastiani Date: Tue, 26 Nov 2024 10:42:51 +0100 Subject: [PATCH] added debug variable + fix attach Signed-off-by: Tullio Sebastiani --- pkg/scenario_orchestrator/common_functions.go | 2 +- tests/containerfiles/dummyscenario/run.sh | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/pkg/scenario_orchestrator/common_functions.go b/pkg/scenario_orchestrator/common_functions.go index f281d7b..c996a34 100644 --- a/pkg/scenario_orchestrator/common_functions.go +++ b/pkg/scenario_orchestrator/common_functions.go @@ -129,7 +129,7 @@ func CommonListRunningScenarios(c ScenarioOrchestrator, ctx context.Context) (*[ for _, index := range indexes { container := (*containersMap)[index] - scenario, err := c.InspectScenario(container, nil) + scenario, err := c.InspectScenario(container, ctx) if err != nil { return nil, err } diff --git a/tests/containerfiles/dummyscenario/run.sh b/tests/containerfiles/dummyscenario/run.sh index 90ffd3d..8e512d8 100755 --- a/tests/containerfiles/dummyscenario/run.sh +++ b/tests/containerfiles/dummyscenario/run.sh @@ -1,5 +1,9 @@ [ -z $END ] && echo '$END variable not exported' && exit 1 [ -z $EXIT_STATUS ] && echo '$EXIT_STATUS variable not exported' && exit 1 +if [[ $DEBUG == 'True' ]]; then + echo "DEBUG MODE ON!" +fi + for i in $(seq 0 $END); do echo "Release the krkn $i" sleep 1