Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CI] googleStorageUploadExt step #24048

Merged
merged 6 commits into from
Feb 16, 2021
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 5 additions & 8 deletions .ci/packaging.groovy
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/env groovy

@Library('apm@current') _
@Library('apm@feature/override-google-storage-step') _
v1v marked this conversation as resolved.
Show resolved Hide resolved

import groovy.transform.Field

Expand Down Expand Up @@ -448,14 +448,11 @@ def publishPackages(baseDir){
uploadPackages("${bucketUri}/${beatsFolderName}", baseDir)
}

def uploadPackages(bucketUri, baseDir){
googleStorageUpload(bucket: bucketUri,
def uploadPackages(bucketUri, beatsFolder){
googleStorageUploadExt(bucket: bucketUri,
credentialsId: "${JOB_GCS_CREDENTIALS}",
pathPrefix: "${baseDir}/build/distributions/",
pattern: "${baseDir}/build/distributions/**/*",
sharedPublicly: true,
showInline: true
)
pattern: "${beatsFolder}/build/distributions/**/*",
sharedPublicly: true)
}

/**
Expand Down
18 changes: 7 additions & 11 deletions Jenkinsfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/env groovy

@Library('apm@current') _
@Library('apm@feature/override-google-storage-step') _
v1v marked this conversation as resolved.
Show resolved Hide resolved

pipeline {
agent { label 'ubuntu-18 && immutable' }
Expand Down Expand Up @@ -311,13 +311,10 @@ def publishPackages(beatsFolder){
* @param beatsFolder the beats folder.
*/
def uploadPackages(bucketUri, beatsFolder){
googleStorageUpload(bucket: bucketUri,
googleStorageUploadExt(bucket: bucketUri,
credentialsId: "${JOB_GCS_CREDENTIALS}",
pathPrefix: "${beatsFolder}/build/distributions/",
pattern: "${beatsFolder}/build/distributions/**/*",
sharedPublicly: true,
showInline: true
)
sharedPublicly: true)
}

/**
Expand Down Expand Up @@ -693,11 +690,10 @@ def archiveTestOutput(Map args = [:]) {
*/
def tarAndUploadArtifacts(Map args = [:]) {
tar(file: args.file, dir: args.location, archive: false, allowMissing: true)
googleStorageUpload(bucket: "gs://${JOB_GCS_BUCKET}/${env.JOB_NAME}-${env.BUILD_ID}",
credentialsId: "${JOB_GCS_CREDENTIALS}",
pattern: "${args.file}",
sharedPublicly: true,
showInline: true)
googleStorageUploadExt(bucket: "gs://${JOB_GCS_BUCKET}/${env.JOB_NAME}-${env.BUILD_ID}",
credentialsId: "${JOB_GCS_CREDENTIALS}",
pattern: "${args.file}",
sharedPublicly: true)
}

/**
Expand Down