Skip to content

Set driftDetection.mode: warn by default for helm releases#1669

Merged
ali-sattari merged 2 commits intomainfrom
ali/SCHED-220/drift-detection-warn
Oct 22, 2025
Merged

Set driftDetection.mode: warn by default for helm releases#1669
ali-sattari merged 2 commits intomainfrom
ali/SCHED-220/drift-detection-warn

Conversation

@ali-sattari
Copy link
Collaborator

@ali-sattari ali-sattari commented Oct 22, 2025

Problem

We need to check whether K8S resources have drifted from helm releases (chart + value).

Solution

We can make use of FluxCD drift detection by setting it to warn, so it emit K8S events on detected drifts.

Testing

Release Notes

Setting driftDetection.mode: warn by default for helm releases in FluxCD.

@Uburro Uburro requested a review from Copilot October 22, 2025 11:25
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR enables FluxCD drift detection in "warn" mode for all Helm releases, allowing the system to emit Kubernetes events when resources drift from their desired state without automatically correcting them. This provides visibility into configuration drift while maintaining manual control over corrections.

Key Changes:

  • Set driftDetection.mode: warn as the default for all Helm release configurations in values.yaml
  • Created a reusable Helm template helper for drift detection configuration
  • Updated all HelmRelease templates to use the new drift detection helper

Reviewed Changes

Copilot reviewed 30 out of 30 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
helm/soperator-fluxcd/values.yaml Added driftDetection configuration with mode: warn to all component definitions
helm/soperator-fluxcd/templates/_helpers.tpl Introduced a helper template for standardized drift detection configuration
helm/soperator-fluxcd/templates/*.yaml Updated all HelmRelease templates to include drift detection using the new helper
helm/soperator-fluxcd/templates/victoria-metrics-operator-crds.yaml Replaced hardcoded drift detection with template helper
helm/soperator-fluxcd/templates/mariadb-operator-crds.yaml Replaced hardcoded drift detection with template helper
fluxcd/base/soperator-fluxcd/resources.yaml Changed drift detection mode from "enabled" to "warn" for the base resource

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@ali-sattari ali-sattari marked this pull request as ready for review October 22, 2025 12:44
@ali-sattari ali-sattari added the helm Functional changes in Helm charts label Oct 22, 2025
asteny
asteny previously approved these changes Oct 22, 2025
@ali-sattari ali-sattari merged commit ac25823 into main Oct 22, 2025
4 checks passed
@ali-sattari ali-sattari deleted the ali/SCHED-220/drift-detection-warn branch October 22, 2025 13:39
ali-sattari added a commit that referenced this pull request Oct 24, 2025
ali-sattari added a commit that referenced this pull request Oct 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

helm Functional changes in Helm charts

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants