How to make jenkins job wait until schedule task completes

218 views
Skip to first unread message

lath...@gmail.com

unread,
Jul 7, 2015, 1:41:05 PM7/7/15
to jenkins...@googlegroups.com
Hello all,

I am launching a schedule task in "windows server 2008" through schtask command in Jenkins job.

What is happening is , the job launches the schedule task and then says build successful. . I am looking for a way for the job to wait until the schedule task completes.

Any inputs on this?

Thanks in advance,
latha.

Baptiste Mathus

unread,
Jul 18, 2015, 9:44:51 AM7/18/15
to jenkins...@googlegroups.com

When using this command through CLI, does it block?

If not this is the reason.

Then you could try and loop+sleep (using powershell ?) until the task has completed.

Cheers

--
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/8c1b6543-85c5-48db-99f5-18bcef364094%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Richard Bywater

unread,
Jul 18, 2015, 6:41:55 PM7/18/15
to jenkins...@googlegroups.com
Can you not just execute the job that is run via the scheduler directly from Jenkins?

Richard.

--
Reply all
Reply to author
Forward
0 new messages