Re: [Declarative Pipeline] Cant use 'path' as parameter name

2017-01-13 Thread Daniel Beck
You're overriding the PATH environment variable. Don't do that. Same with 
'User', 'Home', and a few other parameter names you could think of.

(Yes, it should be case sensitive, but Jenkins doesn't treat it as such 
internally.)

> On 13.01.2017, at 07:38, Dan Tran  wrote:
> 
> The below pipe will work at first checkout,  after that it will fait where 
> jenkins git not able to checkout. looks like 'path' interfere with local env 
> path?
> 
> pipeline {
> 
> parameters {
> string(defaultValue: 'cs/xx', description: 'Path to git path - ex 
> cs/cbs', name: 'path')
> }
> 
> options {
> buildDiscarder(logRotator(numToKeepStr:'2'))
> disableConcurrentBuilds()
> }
> 
> agent any
> 
> stages {
> 
> stage ('do-something') {
> steps {
>   sh "echo ${params.path}"
> }
> }
> }
> }
> 
> here is the error. 
> 
> Caused by: hudson.plugins.git.GitException
> : Command "git fetch --tags --progress 
> ssh://.com/~trand8/xxx-jenkinsfiles.git 
> +refs/heads/*:refs/remotes/origin/*" returned status code 128:
> stdout: 
> stderr: error: cannot run ssh: No such file or directory
> fatal: unable to fork
> 
> 
> Thoughts?
> 
> -D
> 
> 
> 
> 
> -- 
> 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 jenkinsci-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/jenkinsci-users/a2204ec6-b855-4b07-b824-b61c2cbb336f%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
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 jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/29BB6DCD-700A-4D7F-BE0E-BABD4AB0CF00%40beckweb.net.
For more options, visit https://groups.google.com/d/optout.


[Declarative Pipeline] Cant use 'path' as parameter name

2017-01-12 Thread Dan Tran
The below pipe will work at first checkout,  after that it will fait where 
jenkins git not able to checkout. looks like 'path' interfere with local 
env path?

pipeline {

parameters {
string(defaultValue: 'cs/xx', description: 'Path to git path - ex 
cs/cbs', name: 'path')
}

options {
buildDiscarder(logRotator(numToKeepStr:'2'))
disableConcurrentBuilds()
}

agent any

stages {

stage ('do-something') {
steps {
  sh "echo ${params.path}"
}
}
}
}

here is the error. 

Caused by: hudson.plugins.git.GitException 
:
 Command "git fetch --tags --progress 
ssh://.com/~trand8/xxx-jenkinsfiles.git 
+refs/heads/*:refs/remotes/origin/*" returned status code 128:
stdout: 
stderr: error: cannot run ssh: No such file or directory
fatal: unable to fork


Thoughts?


-D



-- 
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 jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/a2204ec6-b855-4b07-b824-b61c2cbb336f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.