fix: refs #6695 try parallel
gitea/salix-front/pipeline/pr-dev There was a failure building this commit Details

This commit is contained in:
Alex Moreno 2025-02-10 15:02:55 +01:00
parent b629cd3c06
commit 0b4ee0f416
1 changed files with 13 additions and 1 deletions

14
Jenkinsfile vendored
View File

@ -172,7 +172,7 @@ pipeline {
def cleanDockerE2E() {
script {
def projectBranch = "${PROJECT_NAME}-${env.BRANCH_NAME}".toLowerCase()
echo "${projectBranch}"
// STOP AND REMOVE
def containers = sh(script: """
docker ps --filter "name=^${projectBranch}" --format "{{.ID}}"
""", returnStdout: true).trim()
@ -185,6 +185,18 @@ def cleanDockerE2E() {
} else {
echo "No se encontraron contenedores con el prefijo '${projectBranch}'."
}
def networks = sh(script: """
docker network ls --filter "name=^${projectBranch}" --format "{{.ID}}"
""", returnStdout: true).trim()
if (networks) {
sh(script: """
echo '${networks}' | xargs docker network rm
""")
} else {
echo "No se encontraron redes con el prefijo '${projectBranch}'."
}
}
}