aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatt Rendina <rendinam@users.noreply.github.com>2018-03-12 17:19:03 -0400
committerGitHub <noreply@github.com>2018-03-12 17:19:03 -0400
commitac297bd2b127b5f9a927a1a5bcccacbc27bcd6c7 (patch)
tree581204011b4dd0d910fd6e550331542412e4e20f
parent117fb2f6587e2d7ec7eab115214a18c30327abdf (diff)
parent90bd4fd01c1738cf9d3b019c4fc799105c598cc1 (diff)
downloaddelivery_control-ac297bd2b127b5f9a927a1a5bcccacbc27bcd6c7.tar.gz
Merge pull request #6 from rendinam/new_outdir
Deposit environment specification files in location of choice.
-rw-r--r--deliver.groovy15
1 files changed, 9 insertions, 6 deletions
diff --git a/deliver.groovy b/deliver.groovy
index ce0adc1..d20cf3d 100644
--- a/deliver.groovy
+++ b/deliver.groovy
@@ -1,10 +1,10 @@
@Library('utils') _
// Parameters made available from Jenkins job configuration:
// delivery_name
-// delivery_iteration
// aux_packages
// conda_installer_version
// conda_version
+// output_dir
def gen_specfiles(label) {
@@ -15,7 +15,6 @@ def gen_specfiles(label) {
deleteDir()
unstash "script"
- sh "pwd; ls -al"
env.PYTHONPATH = ""
// Make the log a bit more deterministic
@@ -27,7 +26,7 @@ def gen_specfiles(label) {
conda.install()
PATH = "${WORKDIR}/miniconda/bin:${PATH}"
- def cpkgs = "conda=${CONDA_VERSION}"
+ def cpkgs = "conda=${conda_version}"
def pkg_list = aux_packages.replaceAll('\n', ' ')
withEnv(["HOME=${HOME}", "PATH=${PATH}"]) {
@@ -53,10 +52,9 @@ node('master') {
daysToKeepStr: '',
numToKeepStr: '4')), pipelineTriggers([])])
stage('create specfiles') {
- sh "pwd; ls -al"
+ deleteDir()
sh "cp -r ${WORKSPACE}@script/*.sh ."
stash name: "script", includes: "*.sh"
- sh "ls -al"
parallel(
Linux: { gen_specfiles('RHEL-6') },
MacOS: { gen_specfiles('OSX-10.11') }
@@ -67,6 +65,11 @@ node('master') {
// Retrieve the spec files from the nodes where they were created.
unstash "spec-stash-RHEL-6"
unstash "spec-stash-OSX-10.11"
- archive "hstdp*txt"
+ hostname = sh(script: "hostname", returnStdout: true).tokenize(".")[0]
+ withCredentials([usernamePassword(credentialsId: '322ad15d-2f5b-4d06-87fa-b45a88596f30',
+ usernameVariable: 'USERNAME',
+ passwordVariable: 'PASSWORD')]) {
+ sh "rsync -avzr hstdp*.txt ${USERNAME}@${hostname}:${output_dir}"
+ }
}
}