Skip to content

Commit f956268

Browse files
authored
Merge pull request #65 from matthewpwilson/getzowe
Install dev version of Zowe CLI from Artifactory
2 parents 2d3c63e + 9461a91 commit f956268

File tree

1 file changed

+11
-7
lines changed

1 file changed

+11
-7
lines changed

Jenkinsfile

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -197,13 +197,17 @@ pipeline {
197197
}
198198
}
199199
steps('Install Zowe CLI') {
200-
timeout(time: 10, unit: 'MINUTES') {
201-
echo "Install Zowe CLI globaly"
202-
sh("npm set registry https://registry.npmjs.org")
203-
sh("npm set @brightside:registry https://api.bintray.com/npm/ca/brightside/")
204-
sh("npm set @zowe:registry https://api.bintray.com/npm/ca/brightside/")
205-
sh("npm install -g @zowe/cli@latest")
206-
sh("zowe --version")
200+
withCredentials([usernamePassword(credentialsId: ARTIFACTORY_CREDENTIALS_ID, usernameVariable: 'USERNAME', passwordVariable: 'API_KEY')]) {
201+
timeout(time: 10, unit: 'MINUTES') {
202+
echo "Install Zowe CLI globaly"
203+
sh "rm -f ~/.npmrc"
204+
sh 'curl -u $USERNAME:$API_KEY https://eu.artifactory.swg-devops.com/artifactory/api/npm/auth/ >> ~/.npmrc'
205+
sh "echo registry=$TEST_NPM_REGISTRY >> ~/.npmrc"
206+
sh "echo @brightside:registry=$TEST_NPM_REGISTRY >> ~/.npmrc"
207+
sh "echo @zowe:registry=$TEST_NPM_REGISTRY >> ~/.npmrc"
208+
sh("npm install -g @zowe/cli@cicsdev")
209+
sh("zowe --version")
210+
}
207211
}
208212
}
209213
}

0 commit comments

Comments
 (0)