From ef343d40872aaca9649cccd9809b8002dc9c2c08 Mon Sep 17 00:00:00 2001 From: Dan Hawkins Date: Mon, 6 Apr 2020 10:04:59 +0100 Subject: [PATCH] GIS-7336 - Bring in FX3 into PS pipeline --- copy/all.groovy | 70 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) create mode 100644 copy/all.groovy diff --git a/copy/all.groovy b/copy/all.groovy new file mode 100644 index 0000000..c492b60 --- /dev/null +++ b/copy/all.groovy @@ -0,0 +1,70 @@ +pipeline { + agent { label "${AGENT_LABEL}" } + stages { + stage('Initial setup') { + steps { + script { + meta = load("${WORKSPACE}/autobuild/Common_scripts/autobuilder.groovy").startnonbuild(this) + } + } + } + stage('Clean exports') { + steps { + script { + IMPORTS = 'imports' + cleanfolders = [ + IMPORTS, + ] + cleaner = load("${autobuilder.commonscripts()}/clean/clean.groovy") + cleaner.clean(cleanfolders) + } + } + } + stage('Import source artifacts') { + steps { + script { + importer = load("${autobuilder.commonscripts()}/import/importer.groovy") + importer.artifactimport(meta, SOURCE_ARTIFACT_LOCATION, SOURCE_ARTIFACT_BUILD_JOB, SOURCE_ARTIFACT_BUILD_SELECTOR, SOURCE_ARTIFACT_RELEASE_REPO, SOURCE_ARTIFACT_RELEASE_REVISION, IMPORTS) + } + } + } + stage('Copy source artifacts') { + steps { + script { + dir(IMPORTS) { + fileOperations([ + fileCopyOperation(excludes: '', + flattenFiles: false, + includes: '**/*', + targetLocation: WORKSPACE) + ]) + } + } + } + } + stage('Archiving artifacts') { + steps { + script { + archiveArtifacts( + artifacts: '**/*', + excludes: "${IMPORTS}/*,autobuild/*" + ) + } + } + } + } + post { + always { + echo 'Post-build' + } + failure { + echo 'Failed build' + } + unstable { + echo 'Unstable build' + } + success { + echo 'Succeeded build' + } + } +} \ No newline at end of file