-
Bug
-
Resolution: Not A Defect
-
Blocker
-
Jenkins 2.60.3
I'm trying to develop a new plugin, kubernetes secrets provider for the credentials plugin, which has a dependency on the kubernetes plugin (for ServiceAccountCredential), however, when including the kubernetes plugin into Maven I cannot build the plugin anymore. As soon as it's removed it works fine.
<dependency> <groupId>org.csanchez.jenkins.plugins</groupId> <artifactId>kubernetes</artifactId> <version>1.0</version> </dependency>
Produces the following error when doing
$ mvn hpi:run [INFO] Scanning for projects... [INFO] [INFO] ------------------------------------------------------------------------ [INFO] Building TODO Plugin 1.0-SNAPSHOT [INFO] ------------------------------------------------------------------------ [INFO] [INFO] >>> maven-hpi-plugin:1.117:run (default-cli) > compile @ kubernetes-secrets >>> [INFO] [INFO] --- maven-hpi-plugin:1.117:validate (default-validate) @ kubernetes-secrets --- [INFO] [INFO] --- maven-enforcer-plugin:1.3.1:display-info (display-info) @ kubernetes-secrets --- [INFO] Maven Version: 3.3.9 [INFO] JDK Version: 1.8.0_121 normalized as: 1.8.0-121 [INFO] OS Info: Arch: x86_64 Family: mac Name: mac os x Version: 10.12.6 [INFO] [INFO] --- maven-enforcer-plugin:1.3.1:enforce (display-info) @ kubernetes-secrets --- [INFO] Restricted to JDK 1.7 yet org.csanchez.jenkins.plugins:kubernetes:jar:1.0:compile contains org/csanchez/jenkins/plugins/kubernetes/ContainerEnvVar$DescriptorImpl.class targeted to JDK 1.8 [WARNING] Rule 2: org.apache.maven.plugins.enforcer.EnforceBytecodeVersion failed with message: Found Banned Dependency: org.csanchez.jenkins.plugins:kubernetes:jar:1.0 Use 'mvn dependency:tree' to locate the source of the banned dependencies. [INFO] ------------------------------------------------------------------------ [INFO] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] Total time: 4.116 s [INFO] Finished at: 2017-09-08T18:56:28+01:00 [INFO] Final Memory: 63M/1038M [INFO] ------------------------------------------------------------------------ [ERROR] Failed to execute goal org.apache.maven.plugins:maven-enforcer-plugin:1.3.1:enforce (display-info) on project kubernetes-secrets: Some Enforcer rules have failed. Look above for specific messages explaining why the rule failed. -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. [ERROR] Re-run Maven using the -X switch to enable full debug logging. [ERROR] [ERROR] For more information about the errors and possible solutions, please read the following articles: [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException