From 0c44c68b1c8aa29de78c4870cdd283ef35aa2da4 Mon Sep 17 00:00:00 2001 From: Lionel Jouin Date: Thu, 16 Feb 2023 18:14:07 +0100 Subject: [PATCH] Meridio: Upload to artifactory Change-Id: I18e15bc4c322b48a09dd60e885e2a0bf604501eb --- jjb/nsm/e2e.Jenkinsfile | 11 +++++++++-- jjb/nsm/meridio-e2e-long-run-test-kind.yaml | 2 -- jjb/nsm/meridio-e2e-test-kind.yaml | 2 -- 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/jjb/nsm/e2e.Jenkinsfile b/jjb/nsm/e2e.Jenkinsfile index 06e0e126..a1ace8f6 100644 --- a/jjb/nsm/e2e.Jenkinsfile +++ b/jjb/nsm/e2e.Jenkinsfile @@ -82,7 +82,7 @@ node('nordix-nsm-build-ubuntu2204') { } stage('Report') { try { - Report().call() + Report(build_number).call() } catch (org.jenkinsci.plugins.workflow.steps.FlowInterruptedException e) { currentBuild.result = 'ABORTED' } catch (Exception e) { @@ -169,7 +169,7 @@ def GetSeed() { } // http://JENKINS_URL/job/meridio-e2e-test-kind/api/json?tree=allBuilds[status,timestamp,id,result,description]{0,9}&pretty=true -def Report() { +def Report(id) { return { def jenkins_url = 'jenkins.nordix.org' @@ -199,8 +199,15 @@ def Report() { ReportIPFamily(success, failure).call() ReportKubernetes(success, failure).call() + sh 'printenv > _output/parameters.txt' + sh "echo 'RESULT=$currentBuild.result' >> _output/parameters.txt" + try { archiveArtifacts artifacts: '_output/**/*.*', followSymlinks: false + sh "tar -czvf ${id}.tar.gz -C _output ." + withCredentials([string(credentialsId: 'nsm-nordix-artifactory-api-key', variable: 'API_KEY')]) { + sh "curl -H 'X-JFrog-Art-Api:${API_KEY}' -T ${id}.tar.gz 'http://artifactory.nordix.org/artifactory/cloud-native/meridio/e2e-test-reports/${id}.tar.gz'" + } } catch (Exception e) { } } diff --git a/jjb/nsm/meridio-e2e-long-run-test-kind.yaml b/jjb/nsm/meridio-e2e-long-run-test-kind.yaml index 70884c5a..678878a2 100644 --- a/jjb/nsm/meridio-e2e-long-run-test-kind.yaml +++ b/jjb/nsm/meridio-e2e-long-run-test-kind.yaml @@ -30,8 +30,6 @@ project-type: pipeline disabled: '{obj:disabled}' - concurrent: false - properties: - github: url: https://github.com/Nordix/Meridio-Operator diff --git a/jjb/nsm/meridio-e2e-test-kind.yaml b/jjb/nsm/meridio-e2e-test-kind.yaml index de9483de..4bf2c1bd 100644 --- a/jjb/nsm/meridio-e2e-test-kind.yaml +++ b/jjb/nsm/meridio-e2e-test-kind.yaml @@ -30,8 +30,6 @@ project-type: pipeline disabled: '{obj:disabled}' - concurrent: false - properties: - github: url: https://github.com/Nordix/Meridio-Operator -- 2.25.1