Skip to content

feat(server-nestjs): configurable Harbor robot expiration with enforced rotation headroom - #2680

Merged
shikanime merged 1 commit into
mainfrom
feat/harbor-robot-expiration
Sep 8, 2026
Merged

feat(server-nestjs): configurable Harbor robot expiration with enforced rotation headroom#2680
shikanime merged 1 commit into
mainfrom
feat/harbor-robot-expiration

Conversation

@shikanime

@shikanime shikanime commented Sep 7, 2026

Copy link
Copy Markdown
Member

Issues liées

Issues numéro:

#2679


Quel est le comportement actuel ?

Les robots Harbor sont créés avec duration: -1, c'est-à-dire sans expiration.
La rotation préventive de leurs secrets Vault est alors incohérente : si une rotation échoue silencieusement, le robot reste valide indéfiniment.

Quel est le nouveau comportement ?

Ajout de HARBOR_ROBOT_EXPIRATION_DAYS dans la config Harbor (par défaut 90 jours), passé comme durée de vie des robots.
HARBOR_ROBOT_ROTATION_THRESHOLD_DAYS est désormais ramené à 60 jours, soit une marge de rotation d'environ un tiers de la durée de vie.
Le seuil est validé par le schéma pour rester strictement inférieur à l'expiration.
Les robots sont donc toujours remplacés avant d'expirer.

Cette PR introduit-elle un breaking change ?

Non.

Autres informations

@github-actions github-actions Bot added the built label Sep 7, 2026
…ed rotation headroom

Robots were created with duration -1 (never expires), making the preventive
rotation of their Vault secrets inconsistent: if a rotation silently failed,
the robot would remain valid forever.
Add HARBOR_ROBOT_EXPIRATION_DAYS (default 90) to the Harbor config and pass
it as the robot duration, and keep the rotation headroom at roughly a third
of the lifetime by lowering HARBOR_ROBOT_ROTATION_THRESHOLD_DAYS to 60.
HARBOR_ROBOT_ROTATION_THRESHOLD_DAYS is now schema-enforced to stay strictly
below the expiration, so robots are always replaced before they expire.
Refs #2679
Signed-off-by: William Phetsinorath <william.phetsinorath-open@interieur.gouv.fr>
Change-Id: I1888d03cdbc54a3dbd00a027f69134c26a6a6964

Signed-off-by: William Phetsinorath <william.phetsinorath-open@interieur.gouv.fr>
Change-Id: I1888d03cdbc54a3dbd00a027f69134c26a6a6964
@shikanime
shikanime force-pushed the feat/harbor-robot-expiration branch from 5fdea26 to 0835297 Compare September 8, 2026 15:35
@shikanime
shikanime marked this pull request as ready for review September 8, 2026 15:39
@shikanime
shikanime requested a review from a team as a code owner September 8, 2026 15:39
@shikanime shikanime self-assigned this Sep 8, 2026
@shikanime shikanime added the enhancement New feature or request label Sep 8, 2026
@shikanime shikanime added this to the 9.26.0 milestone Sep 8, 2026

@StephaneTrebel StephaneTrebel left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Même forme que côté Gitlab, ça me va bien 👍

@shikanime
shikanime enabled auto-merge September 8, 2026 15:44
@cloud-pi-native-sonarqube

Copy link
Copy Markdown

@shikanime
shikanime added this pull request to the merge queue Sep 8, 2026
Merged via the queue into main with commit c55fe13 Sep 8, 2026
63 checks passed
@shikanime
shikanime deleted the feat/harbor-robot-expiration branch September 8, 2026 16:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

built enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants