Hi.
Here's my use case: I have 6 credentials of type "secret file". Their IDs
are:
project1_integration
project1_acceptance
project1_production
project2_integration
project2_acceptance
project2_production
I also have two projects project1 and project2. I want project1 to have a
dropdown parameter that would allow to choose one of three secret files and
project2 to have its own dropdown to choose one of the other three secret
files.
I tried to create a simple choice parameter with name: CREDS_ID and allowed
values being the credentials IDs. Then I checked "Use secret text(s) or
file(s)" and entered the expression ${CREDS_ID} . The build failed with
"CredentialNotFoundException", just like here:
https://issues.jenkins-ci.org/browse/JENKINS-31946?focusedCommentId=243381&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-243381
If instead I create a parameter of type "Credentials", the expansion works
fine. It's strange, because in the end the plugin calls
findCredentialById() which accepts the string id. With this parameter the
dropdown contains all 6 credentials. I see no decent way to limit them.
--
You received this message because you are subscribed to the Google Groups
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/jenkinsci-users/227fba6c-12c0-4914-9250-8462e983ce76%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.