I want Jenkins job to build every two weeks

后端 未结 4 1905
悲哀的现实
悲哀的现实 2020-12-18 00:12

Will this expression run the build every other Friday at noon? Assume i set this up on a Friday?

0 12 * * */14

I tried 0 12 * * FRI/14 but Jenkins returned a

4条回答
  •  北海茫月
    2020-12-18 00:50

    You'll have to add some logic to the build script to determine if it ran last week, and then run it every week.

    I looked around similar questions for cron jobs, and you have to do some shell magic to make it work.

    You could try what was suggested here:

    H H 8-14,22-28 * 5

    Which would qualify on Fridays that are in the second or fourth week of the month.

提交回复
热议问题