From b04c769d65e12882283c3fc288cedcf38fb342d2 Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Fri, 2 Aug 2019 18:51:51 +0200 Subject: [PATCH] Jenkinsfile: split some shell steps Signed-off-by: Sebastiaan van Stijn --- Jenkinsfile | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index cd16699796..4afddcafb0 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -67,7 +67,9 @@ pipeline { sh ''' echo 'Ensuring container killed.' docker rm -vf docker-pr$BUILD_NUMBER || true - + ''' + + sh ''' echo 'Chowning /workspace to jenkins user' docker run --rm -v "$WORKSPACE:/workspace" busybox chown -R "$(id -u):$(id -g)" /workspace ''' @@ -137,7 +139,9 @@ pipeline { sh ''' echo "Ensuring container killed." docker rm -vf docker-pr$BUILD_NUMBER || true - + ''' + + sh ''' echo "Chowning /workspace to jenkins user" docker run --rm -v "$WORKSPACE:/workspace" busybox chown -R "$(id -u):$(id -g)" /workspace ''' @@ -193,7 +197,9 @@ pipeline { sh ''' echo "Ensuring container killed." docker rm -vf docker-pr-exp$BUILD_NUMBER || true - + ''' + + sh ''' echo "Chowning /workspace to jenkins user" docker run --rm -v "$WORKSPACE:/workspace" busybox chown -R "$(id -u):$(id -g)" /workspace ''' @@ -249,7 +255,9 @@ pipeline { sh ''' echo "Ensuring container killed." docker rm -vf docker-pr-$BUILD_NUMBER || true - + ''' + + sh ''' echo "Chowning /workspace to jenkins user" docker run --rm -v "$WORKSPACE:/workspace" busybox chown -R "$(id -u):$(id -g)" /workspace ''' @@ -305,7 +313,9 @@ pipeline { sh ''' echo "Ensuring container killed." docker rm -vf docker-pr$BUILD_NUMBER || true - + ''' + + sh ''' echo "Chowning /workspace to jenkins user" docker run --rm -v "$WORKSPACE:/workspace" busybox chown -R "$(id -u):$(id -g)" /workspace '''