Re: Running Job from pipleline - old code is excuted

11 views
Skip to first unread message

Slide

unread,
Jan 11, 2017, 11:49:33 AM1/11/17
to Jenkins Users

Just curious, why do you have a node() inside of a node()?


On Wed, Jan 11, 2017, 09:01 Boaz Nahum <boaz...@gmail.com> wrote:
Hi.

I'm using Jenkins 2.32.1 running on WIndows Server

The jenkinsfile that describe the pipeline is something like this:
node('boaz') {

    println "Hello from node ${env.NODE_NAME}"

    stage('preparation') {

        node('boaz') {

            def parameters = [

                [$class: 'StringParameterValue', name: 'param_sandbox_path', value: '${sandboxPath}']



            ];

            build job: "periodic-build-1-preparation", parameters: parameters
        }
    }
}

I'm not using SCM to create workspace. 

The job "periodic-build-1-preparation" The job is freestyle job with one build step which is shell script
The job started and run as expected. Then I change it, but no matter what I tried to do - the old job code is running. I know it because it is shell script that echo the commands before running.

Thanks
Boaz





--
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-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/7bed6558-fce2-4c26-a7c9-1fb91a3ab02d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Peter McNab

unread,
Jan 11, 2017, 12:38:40 PM1/11/17
to jenkins...@googlegroups.com

I saw a case like then after I changed the name of my Jenkinsfile, but forgot to update the filename in the "script to execute" part of the job configuration.

Somewhat surprised to see that my workspace wasn't being cleaned between jobs, but it had me scratching my head for a bit.

Pete

Reply all
Reply to author
Forward
0 new messages