Created
July 11, 2019 07:23
-
-
Save alipandidan/c6981522f9af01adf83dc2ad13b9c8b0 to your computer and use it in GitHub Desktop.
List Jenkins Credentials
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def StandardUsernameCredentials = com.cloudbees.plugins.credentials.CredentialsProvider.lookupCredentials(com.cloudbees.plugins.credentials.common.StandardUsernameCredentials.class, Jenkins.instance, null, null); | |
for (c in StandardUsernameCredentials) { | |
println(c.id + ": " + c.description) | |
} | |
def StandardUsernamePasswordCredentials = com.cloudbees.plugins.credentials.CredentialsProvider.lookupCredentials(com.cloudbees.plugins.credentials.common.StandardUsernamePasswordCredentials.class, Jenkins.instance, null, null); | |
for (c in StandardUsernamePasswordCredentials) { | |
println(c.id + ": " + c.description) | |
} | |
def IdCredentials = com.cloudbees.plugins.credentials.CredentialsProvider.lookupCredentials( com.cloudbees.plugins.credentials.common.IdCredentials.class, Jenkins.instance, null, null); | |
for (c in IdCredentials) { | |
println(c.id + ": " + c.description) | |
} | |
def StandardCertificateCredentialsCredentials = com.cloudbees.plugins.credentials.CredentialsProvider.lookupCredentials( com.cloudbees.plugins.credentials.common.StandardCertificateCredentials.class, Jenkins.instance, null, null ); | |
for (c in StandardCertificateCredentialsCredentials) { | |
println(c.id + ": " + c.description) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment