Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New HelmOps Controller #2962

Open
manno opened this issue Oct 18, 2024 · 0 comments
Open

New HelmOps Controller #2962

manno opened this issue Oct 18, 2024 · 0 comments

Comments

@manno
Copy link
Member

manno commented Oct 18, 2024

Users want to use Fleet to deploy Helm charts directly. That way they can use Fleet as a multi-cluster deployer.

Fleet is already able to deploy to all clusters registered to Rancher.
However, currently Fleet is only able to deploy from Git or “Bundle”. To deploy from Git the configuration has to be entered in both Rancher (where is the Git repository) and in Git (what to deploy and how to configure it).
To deploy from “Bundle”, helm charts have to be converted with the Fleet CLI tool first. This is possible for internal usage, but didn’t become popular in the wider community.

Description

We create a new resource, e.g. “Fleet CRD”, which contains most of the fields from fleet.yaml and some from GitRepo CRD.

When the new CRD changes, we install/update the chart. This makes use of the existing pull based mechanism, without storing the chart in k8s resources. The agent will download the chart directly from the container registry.

Fields from GitRepo

  • helmSecretName
  • caBundle
  • insecureSkipTLSVerify
  • serviceAccount
  • targets
  • correctDrift

UI

Since all fields are configurable in the CRD, this allows for a rich UI. In the GitOps UI, only the Git repository server and a few fields can be configured. The Fleet CRD allows full control over the installation through all fields that were previously only available in the fleet.yaml.

For example:

  • namespace
  • defaultNamespace
  • namespaceLabels
  • namespaceAnnotations
  • labels
  • kustomize
  • helm options
  • paused
  • rolloutStrategy
  • targetCustomizations
  • dependsOn
  • ignore

Future Ideas

Not part of the first iteration:

  • The helm chart could be checked regularly at a configured polling interval, like we do for GitOps. This makes sense if the version tag is “latest”, for example.
  • Support conversion from manifest-style sources to Helm charts.

Implementation

Create the FleetCRD and a new reconciler which will create a bundle similar to how OCI storage works. The fleet-agent needs to pull and deploy that bundle type without the helm conversion.

@manno manno added this to Fleet Oct 18, 2024
@manno manno converted this from a draft issue Oct 18, 2024
@0xavi0 0xavi0 self-assigned this Oct 21, 2024
@0xavi0 0xavi0 modified the milestones: v2.10.0, v2.11.0 Oct 21, 2024
@manno manno mentioned this issue Oct 23, 2024
@manno manno moved this from 📋 Backlog to 🏗 In progress in Fleet Oct 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: 🏗 In progress
Development

No branches or pull requests

3 participants