-
Bug
-
Resolution: Unresolved
-
Minor
-
None
-
Docker Container
Alpine 3.7
Jenkins 2.101
pipeline-utility-steps-2.0.1
Apache Maven 3.3.9 (bb52d8502b132ec0a5a3f4c09453c07478323dc5; 2015-11-10T16:41:47+00:00)
Maven home: /java/mvn-3.3.9
Java version: 1.8.0_161, vendor: Oracle Corporation
Java home: /java/jdk-1.8u161-b12/jre
Default locale: en, platform encoding: UTF-8
OS name: "linux", version: "4.15.7-2.g353046a-default", arch: "amd64", family: "unix"
Docker Container Alpine 3.7 Jenkins 2.101 pipeline-utility-steps-2.0.1 Apache Maven 3.3.9 (bb52d8502b132ec0a5a3f4c09453c07478323dc5; 2015-11-10T16:41:47+00:00) Maven home: /java/mvn-3.3.9 Java version: 1.8.0_161, vendor: Oracle Corporation Java home: /java/jdk-1.8u161-b12/jre Default locale: en, platform encoding: UTF-8 OS name: "linux", version: "4.15.7-2.g353046a-default", arch: "amd64", family: "unix"
We have a Jenkins job which tests out product using different tools such as sbt, maven, gradle and so on. Our build runs in parallel on multiple nodes and we wanted to "zip" some artifacts from the target directories for easier debugging.
According to the documentation (as well as the generated Pipeline snippet from the Pipeline Syntax page) the following line should be working just fine:
zip archive: true, dir: './maven/target', glob: '', zipFile: 'maven-target.zip'
Unfortunately this is not the case and we receive the following exception:
org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed: WorkflowScript: 43: Invalid parameter "archive", did you mean "url"? @ line 43, column 33. zip archive: true, dir: './maven/target', glob: '', zipFile: 'maven-target.zip' ^ WorkflowScript: 43: Invalid parameter "dir", did you mean "url"? @ line 43, column 48. zip archive: true, dir: './ma ^ WorkflowScript: 43: Invalid parameter "glob", did you mean "label"? @ line 43, column 71. true, dir: './maven/target', glob: '', ^ WorkflowScript: 43: Invalid parameter "zipFile", did you mean "label"? @ line 43, column 81. : './maven/target', glob: '', zipFile: ' ^ 4 errors at org.codehaus.groovy.control.ErrorCollector.failIfErrors(ErrorCollector.java:310) at org.codehaus.groovy.control.CompilationUnit.applyToPrimaryClassNodes(CompilationUnit.java:1085) at org.codehaus.groovy.control.CompilationUnit.doPhaseOperation(CompilationUnit.java:603) at org.codehaus.groovy.control.CompilationUnit.processPhaseOperations(CompilationUnit.java:581) at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:558) at groovy.lang.GroovyClassLoader.doParseClass(GroovyClassLoader.java:298) at groovy.lang.GroovyClassLoader.parseClass(GroovyClassLoader.java:268) at groovy.lang.GroovyShell.parseClass(GroovyShell.java:688) at groovy.lang.GroovyShell.parse(GroovyShell.java:700) at org.jenkinsci.plugins.workflow.cps.CpsGroovyShell.doParse(CpsGroovyShell.java:133) at org.jenkinsci.plugins.workflow.cps.CpsGroovyShell.reparse(CpsGroovyShell.java:127) at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.parseScript(CpsFlowExecution.java:557) at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.start(CpsFlowExecution.java:518) at org.jenkinsci.plugins.workflow.job.WorkflowRun.run(WorkflowRun.java:290) at hudson.model.ResourceController.execute(ResourceController.java:97) at hudson.model.Executor.run(Executor.java:429) Finished: FAILURE
I've attached the Jenkinsfile we currently have as well as the log file. This issue appears to be similar to JENKINS-44078.
- relates to
-
JENKINS-44078 "zip" step is not working according to the documentation
-
- Reopened
-
Works in script blocks:
https://issues.jenkins-ci.org/browse/JENKINS-44078?focusedCommentId=349855&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-349855