user3409586
user3409586

Reputation: 11

Jenkins - How to schedule job every period of days?

I tried to schedule a job run every 28 days but still not have solution yet. Please help! Thank!

Upvotes: 0

Views: 5041

Answers (2)

Gayoung Lee
Gayoung Lee

Reputation: 1

I didn't try it yet so I may be wrong, but how about putting days as hours. For example, if you want to run Jenkins job every 10 days, you schedule it to run every 240 hours.

Upvotes: 0

Christopher Orr
Christopher Orr

Reputation: 111555

As the documentation shows, using */X executes in intervals of X.

So, applying this to the "day of month" field, under "Build periodically", you could use the following to build at some consistent point in time once every 28 days:

H H */28 * 2

As an example, the 2 at the end signifies that the build should run on a Tuesday. Otherwise, it will probably build on whatever day of the week the current month started with.

Upvotes: 1

Related Questions