Skip to content
This repository has been archived by the owner on Nov 25, 2024. It is now read-only.

Bundle prebuilds in the package on NPM registry #58

Merged
merged 4 commits into from
Feb 4, 2022
Merged
Show file tree
Hide file tree
Changes from 3 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
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@

All notable changes to the Secure Credential Store Plug-in for Zowe CLI will be documented in this file.

## Recent Changes

- BugFix: Added prebuilt Keytar binaries to the package for installation from registry. [#53](https://github.com/zowe/zowe-cli-scs-plugin/issues/53)
- BugFix: Pruned dev dependencies from npm-shrinkwrap file.

## `4.1.7`

- BugFix: Included an npm-shrinkwrap file to lock-down all transitive dependencies.
Expand Down
16 changes: 3 additions & 13 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -167,20 +167,10 @@ node('zowe-jenkins-agent-dind') {
stage: {
def packageJson = readJSON file: "package.json"
def keytarVer = packageJson.dependencies['keytar']
def uploadUrlArtifactory = "https://zowe.jfrog.io/artifactory/libs-snapshot-local/org/zowe/cli/zowe-cli-prebuilds/keytar-${keytarVer}-prebuilds.tgz"

// If Keytar prebuilds TGZ doesn't exist yet on Artifactory, create and upload it
if (sh(returnStatus: true, script: "curl -fs --head ${uploadUrlArtifactory}") != 0) {
withCredentials([usernamePassword(credentialsId: 'zowe-robot-github', usernameVariable: 'USERNAME', passwordVariable: 'TOKEN')]) {
sh "bash jenkins/bundleKeytar.sh ${keytarVer} \"${USERNAME}:${TOKEN}\""
}

withCredentials([usernamePassword(credentialsId: 'zowe.jfrog.io', usernameVariable: 'USERNAME', passwordVariable: 'PASSWORD')]) {
sh "curl -f -u ${USERNAME}:${PASSWORD} --data-binary \"@keytar-prebuilds.tgz\" -H \"Content-Type: application/x-gzip\" -X PUT ${uploadUrlArtifactory}"
}
} else {
echo "Skipping upload to Artifactory because \"keytar-${keytarVer}-prebuilds.tgz\" already exists"
withCredentials([usernamePassword(credentialsId: 'zowe-robot-github', usernameVariable: 'USERNAME', passwordVariable: 'TOKEN')]) {
sh "bash jenkins/bundleKeytar.sh ${keytarVer} \"${USERNAME}:${TOKEN}\""
}
archiveArtifacts artifacts: "keytar-prebuilds.tgz"
}
)

Expand Down
Loading