Skip to content

Commit

Permalink
Download manifest bug
Browse files Browse the repository at this point in the history
Signed-off-by: Prudhvi Godithi <[email protected]>
  • Loading branch information
prudhvigodithi committed Jul 30, 2024
1 parent 3822ade commit 13d57a4
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion tests/jenkins/TestRunBenchmarkTestScript.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ class TestRunBenchmarkTestScript extends BuildPipelineTest {

assertThat(curlCommands.size(), equalTo(2))
assertThat(curlCommands, hasItem(
"curl -sSL test://artifact.url --output tests/data/opensearch-1.3.0-bundle.yml".toString()
"curl -sSL --retry 5 test://artifact.url --output tests/data/opensearch-1.3.0-bundle.yml".toString()
))

def s3DownloadCommands = getCommandExecutions('s3Download', 'bucket').findAll {
Expand Down
2 changes: 1 addition & 1 deletion tests/jenkins/TestRunPerfTestScript.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ class TestRunPerfTestScript extends BuildPipelineTest {

assertThat(curlCommands.size(), equalTo(2))
assertThat(curlCommands, hasItem(
"curl -sSL test://artifact.url --output tests/data/opensearch-1.3.0-bundle.yml".toString()
"curl -sSL --retry 5 test://artifact.url --output tests/data/opensearch-1.3.0-bundle.yml".toString()
))

def s3DownloadCommands = getCommandExecutions('s3Download', 'bucket').findAll {
Expand Down
5 changes: 3 additions & 2 deletions vars/downloadBuildManifest.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,9 @@
*/
def call(Map args = [:]) {
def lib = library(identifier: "jenkins@main", retriever: legacySCM(scm))

sh "curl -sSL ${args.url} --output ${args.path}"
sh "mkdir -p \$(dirname \"${args.path}\")"
sh "touch ${args.path}"
sh "curl -sSL --retry 5 ${args.url} --output ${args.path}"
def buildManifestObj = lib.jenkins.BuildManifest.new(readYaml(file: args.path))
return buildManifestObj
}

0 comments on commit 13d57a4

Please sign in to comment.