mirror of
https://github.com/SAP/jenkins-library.git
synced 2024-12-14 11:03:09 +02:00
This reverts commit e64895e022
.
This commit is contained in:
parent
e64895e022
commit
767575e75c
@ -247,24 +247,13 @@ void executeOnPod(Map config, utils, Closure body, Script script) {
|
||||
}
|
||||
echo "ContainerConfig: ${containerParams}"
|
||||
container(containerParams) {
|
||||
Exception e
|
||||
try {
|
||||
utils.unstashAll(stashContent)
|
||||
echo "invalidate stash workspace-${config.uniqueId}"
|
||||
stash name: "workspace-${config.uniqueId}", excludes: '**/*', allowEmpty: true
|
||||
body()
|
||||
} catch(Exception e1) {
|
||||
e = e1
|
||||
} finally {
|
||||
try {
|
||||
stashWorkspace(config, 'container', true, true)
|
||||
} catch(Exception e2) {
|
||||
if(e) {
|
||||
e.addSuppressed(e2)
|
||||
throw e
|
||||
}
|
||||
throw e2
|
||||
}
|
||||
stashWorkspace(config, 'container', true, true)
|
||||
}
|
||||
}
|
||||
} else {
|
||||
@ -327,8 +316,8 @@ chown -R ${runAsUser}:${fsGroup} ."""
|
||||
return stashName
|
||||
} catch (AbortException | IOException e) {
|
||||
echo "${e.getMessage()}"
|
||||
throw e
|
||||
}
|
||||
return null
|
||||
}
|
||||
|
||||
private Map getSecurityContext(Map config) {
|
||||
|
Loading…
Reference in New Issue
Block a user