Combination triggers possible?

36 views
Skip to first unread message

uscen...@gmail.com

unread,
Dec 3, 2015, 2:51:50 AM12/3/15
to Jenkins Users
Not sure if what I am trying to do is possible.

Here is what I am trying to accomplish:
  • Project A builds at the top of the hour.
  • Project B needs to build 20 minutes later but only if the build in Project A passes.
Can this be done?  

Victor Martinez

unread,
Dec 3, 2015, 7:23:09 AM12/3/15
to Jenkins Users
Hi,

 I've not found any plugin in order to pause Project A for X minutes, but you could add some shell script to 'sleep 1200' and then run a postbuild action to trigger Project B
It's not the smarter solution at all, maybe someone else can give a better proposal 

Cheers

uscen...@gmail.com

unread,
Dec 3, 2015, 7:32:26 PM12/3/15
to Jenkins Users
Thanks Victor for the reply. I was able to use a work around and so far seems good enough. This is what I did.

Schedule Project A to build at the top of the hour.
Added a post build step to trigger a build on Project B
On Project B I added a quiet period of 1200 and a pre-requisite build step to check for Project A build success. (used the prerequisite build step plugin)

Baptiste Mathus

unread,
Dec 4, 2015, 11:52:25 AM12/4/15
to jenkins...@googlegroups.com

Might be an use case for workflow, the advantage being also that it should let you avoid having a slave locked just to sleep.
I think that if you set a sleep outside a node block in a workflow script you should get that.

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/6baeb5fd-d39e-49b1-984e-285ccd73e183%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

uscen...@gmail.com

unread,
Jan 12, 2016, 3:17:25 PM1/12/16
to Jenkins Users, m...@batmat.net
Thanks Baptiste,

While our solution works for now I will be implementing the workflows a long term solution.
Reply all
Reply to author
Forward
0 new messages