-
Bug
-
Resolution: Unresolved
-
Minor
-
None
The following Job DSL cannot resolve a var passed for the classpath parameter
stringParam('SHARED_JAR_PATH' 'file:////Users/cmoullia/temp/demo/lib/build/libs/lib-0.1.0.jar','Path where the shared lib is available n the jenkins instance') ... postBuildSteps { systemGroovyCommand(readFileFromWorkspace('restorePOM.groovy')) systemGroovyCommand(script) { classpath('$SHARED_JAR_PATH') }
Then we got this error
ERROR: (script, line 101) classpath must be a valid URL: no protocol: $SHARED_JAR_PATH
As you can see the var name is passed and not extrapolated to get the value
[JENKINS-64515] Classpath of systemGroovyCommand cannot resolve a var
Description |
Original:
{{The following Job DSL cannot resolve a var passed for the classpath parameter}}
{{}} {{}} {code:java} stringParam('SHARED_JAR_PATH' 'file:////Users/cmoullia/temp/demo/lib/build/libs/lib-0.1.0.jar','Path where the shared lib is available n the jenkins instance') ... postBuildSteps { systemGroovyCommand(readFileFromWorkspace('restorePOM.groovy')) systemGroovyCommand(script) { classpath('$SHARED_JAR_PATH') }{code} {{}} Then we got this error {code:java} ERROR: (script, line 101) classpath must be a valid URL: no protocol: $SHARED_JAR_PATH{code} As you can see the var name is passed and not extrapolated to get the value {{}} |
New:
{{The following Job DSL cannot resolve a var passed for the classpath parameter}}
{code:java} stringParam('SHARED_JAR_PATH' 'file:////Users/cmoullia/temp/demo/lib/build/libs/lib-0.1.0.jar','Path where the shared lib is available n the jenkins instance') ... postBuildSteps { systemGroovyCommand(readFileFromWorkspace('restorePOM.groovy')) systemGroovyCommand(script) { classpath('$SHARED_JAR_PATH') }{code} Then we got this error {code:java} ERROR: (script, line 101) classpath must be a valid URL: no protocol: $SHARED_JAR_PATH{code} As you can see the var name is passed and not extrapolated to get the value |
Assignee | Original: Daniel Spilker [ daspilker ] | New: Jamie Tanna [ jamietanna ] |