通过JobDSL插件创建绑定到文件夹的StringCredentials类型的凭据



我正在运行Jenkins 2.204.5
插件:
-job dsl v1.77
-credentials 1.7

我正试图使用JobDSL插件代码创建一个绑定到文件夹的"secret Text"或"StringCredentialsImpl"类型的秘密。https://github.com/jenkinsci/plain-credentials-plugin/blob/master/src/main/java/org/jenkinsci/plugins/plaincredentials/impl/StringCredentialsImpl.java

但是,尽管它在https://github.com/jenkinsci/job-dsl-plugin/blob/master/job-dsl-core/src/main/groovy/javaposse/jobdsl/dsl/helpers/parameter/CredentialsParameterContext.groovy#L23

我在我的动态查看器JENKINS_URL/plugin/job dsl/api viewer/index.html中看不到它我看到的只是:

credentials {
basicSSHUserPrivateKey {}
certificateCredentialsImpl {}
fileSystemServiceAccountCredential {}
// OpenShift do use a dedicated authorization layer on top of Kubernetes and does not allow to access Kubernetes API using plain username/password credentials.
openShiftBearerTokenCredentialImpl {}
usernamePasswordCredentialsImpl {}
}

显然,纯凭据插件毕竟与作业dsl插件不兼容。

Jenkins错误:https://issues.jenkins-ci.org/browse/JENKINS-59971

相关内容

  • 没有找到相关文章

最新更新