added age-based build retention: artifacts.retentionMaxAge (e.g. 30d, empty = no limit) drops builds older than the given age; combines with retentionPerBranch as independent caps — a build is kept only while it satisfies both limits; a branch's newest build is never age-pruned and keepLatestGreen now shields the latest green build from both limits, keeping the permanent /branches/... links valid
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Fable 5
parent
b104eeee05
commit
d0b38c557a
@@ -71,9 +71,17 @@ data class BuildsConfig(
|
||||
data class ArtifactsConfig(
|
||||
val retentionPerBranch: Int = 3,
|
||||
/**
|
||||
* Keep each branch's latest green (SUCCESS) build beyond [retentionPerBranch],
|
||||
* so the permanent `/branches/<branch-key>/…` artifact URLs stay valid while newer
|
||||
* builds fail; the build is still dropped once its branch is gone from origin.
|
||||
* Additionally drop builds older than this age (e.g. `30d` or `12h`); empty means no
|
||||
* age limit. Combines with [retentionPerBranch] — a build is kept only while it
|
||||
* satisfies both limits. A branch's newest build is never age-pruned, so dormant
|
||||
* branches keep their last status.
|
||||
*/
|
||||
val retentionMaxAge: String = "",
|
||||
/**
|
||||
* Keep each branch's latest green (SUCCESS) build beyond [retentionPerBranch] and
|
||||
* [retentionMaxAge], so the permanent `/branches/<branch-key>/…` artifact URLs stay
|
||||
* valid while newer builds fail; the build is still dropped once its branch is gone
|
||||
* from origin.
|
||||
*/
|
||||
val keepLatestGreen: Boolean = true,
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user