def results = server.download(downloadSpec)
// Save the list of URLs that we need to pass to the dockerfiles for build
def debian_packages = []
- for ( result in results.getDependencies()) {
+ for ( result in results.getDependencies() ) {
if (result.remotePath.contains(".deb")) {
debian_packages.add(result.remotePath)
}
}
// workaround. flatten repo to remove specific build num from the directory
- sh "cp -R ${branch}/${build_number}/* ."
- sh "rm -rf ${branch}/${build_number}"
+ sh "cp -Rv ${branch}/${build_number}/* ."
+ sh "rm -rfv ${branch}/${build_number}"
return debian_packages
}
///////////////////////////////////////////////////////////////////////////////////////
stage('Copy Artifacts') {
// cleanup any previous repo
- sh 'rm -rf repo'
+ sh "pwd"
+ sh "tree -fD repo"
+ sh "lsof repo"
+ sh "rm -rfv repo"
dir('repo') {
packageList = []
dir("${RELEASE}") {
} // if (params.SAVE_ARTIFACTS_OVERRIDE || stage_archive)
} // dir(OSM_DEVOPS)
} finally {
- stage('Archive Container Logs') {
- if ( ARCHIVE_LOGS_FLAG ) {
+ stage('Archive Container Logs') {
+ if (ARCHIVE_LOGS_FLAG) {
try {
// Archive logs
remote = [
} // end if ( ARCHIVE_LOGS_FLAG )
}
stage('Cleanup') {
- if ( params.DO_INSTALL && server_id != null) {
+ if (params.DO_INSTALL && server_id != null) {
delete_vm = true
- if (error && params.SAVE_CONTAINER_ON_FAIL ) {
+ if (error && params.SAVE_CONTAINER_ON_FAIL) {
delete_vm = false
}
- if (!error && params.SAVE_CONTAINER_ON_PASS ) {
+ if (!error && params.SAVE_CONTAINER_ON_PASS) {
delete_vm = false
}
- if ( delete_vm ) {
+ if (delete_vm) {
if (server_id != null) {
println("Deleting VM: $server_id")
sh """#!/bin/sh -e
}
}
}
- if ( http_server_name != null ) {
+ if (http_server_name != null) {
sh "docker stop ${http_server_name} || true"
sh "docker rm ${http_server_name} || true"
}
- if ( devopstempdir != null ) {
+ if (devopstempdir != null) {
sh "rm -rf ${devopstempdir}"
}
}