X-Git-Url: https://osm.etsi.org/gitweb/?a=blobdiff_plain;f=jenkins%2Fci-pipelines%2Fci_stage_3.groovy;h=42fbe1ee60b33702eefdc9e0d2cb78179ca828cb;hb=bfb7790d10dfc34c17976c8e60372543af33a618;hp=1809d02b835e66ddae2d7c96c8502fdaae432333;hpb=16a96f533dd64b08cdd980eef13d3f982c99f19e;p=osm%2Fdevops.git diff --git a/jenkins/ci-pipelines/ci_stage_3.groovy b/jenkins/ci-pipelines/ci_stage_3.groovy index 1809d02b..42fbe1ee 100644 --- a/jenkins/ci-pipelines/ci_stage_3.groovy +++ b/jenkins/ci-pipelines/ci_stage_3.groovy @@ -235,7 +235,12 @@ node("${params.NODE}") { repo_base_url = "-u ${params.REPOSITORY_BASE}" } if ( params.DO_STAGE_4 ) { + try { sh "docker stack list |grep \"${container_name_prefix}\"| awk '{ print \$1 }'| xargs docker stack rm" + } + catch (caughtError) { + println("Caught error: docker stack rm failed!") + } } sh """ export PATH=$PATH:/snap/bin