CSIT uplift for CBS, generalized DFC, bugfixes, stability, traceability
Issue-ID: DCAEGEN2-1719
Change-Id: If5c96a7f205a34f78e50585a7187c5b9a3820023
Signed-off-by: TamasBakai <tamas.bakai@est.tech>
diff --git a/scripts/dcaegen2-collectors-datafile/dfc-containers-clean.sh b/scripts/dcaegen2-collectors-datafile/dfc-containers-clean.sh
index 0391934..0e7c34e 100755
--- a/scripts/dcaegen2-collectors-datafile/dfc-containers-clean.sh
+++ b/scripts/dcaegen2-collectors-datafile/dfc-containers-clean.sh
@@ -1,11 +1,15 @@
#!/bin/bash
-
# Kill dfc and all simulator
-docker kill dfc_app
-docker kill dfc_dr-sim
-docker kill dfc_dr-redir-sim
-docker kill dfc_mr-sim
-docker kill dfc_sftp-server
-docker kill dfc_ftpes-server-vsftpd
+running_containers=$(docker ps --filter name=dfc_ -q)
+
+
+if [ -z "$running_containers" ]
+then
+ echo "No container requires termination"
+else
+ echo "Stopping and removing containers"
+ docker stop $running_containers
+ docker rm $running_containers
+fi