Merge pull request #196 from fluxcd/docs/helmrelease-guide-changes

pull/191/head
Hidde Beydals 5 years ago committed by GitHub
commit 8b9abfb26e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -6,18 +6,20 @@ releases with Kubernetes manifests.
![](../../_files/helm-controller.png) ![](../../_files/helm-controller.png)
The desired state of a Helm release is described through a Kubernetes Custom Resource named `HelmRelease`. The desired state of a Helm release is described through a Kubernetes Custom Resource named `HelmRelease`.
Based on the creation, mutation or removal of a HelmRelease resource in the cluster, Based on the creation, mutation or removal of a `HelmRelease` resource in the cluster,
Helm actions are performed by the controller. Helm actions are performed by the controller.
Features: Features:
- Watches for `HelmRelease` objects and generates `HelmChart` objects - Watches for `HelmRelease` objects and generates `HelmChart` objects
- Supports `HelmChart` artifacts produced from `HelmRepository` and `GitRepository` sources
- Fetches artifacts produced by [source-controller](../source/controller.md) from `HelmChart` objects - Fetches artifacts produced by [source-controller](../source/controller.md) from `HelmChart` objects
- Watches `HelmChart` objects for revision changes (semver ranges) - Watches `HelmChart` objects for revision changes (including semver ranges for charts from `HelmRepository` sources)
- Performs Helm v3 actions including Helm tests as configured in the `HelmRelease` objects - Performs automated Helm actions, including Helm tests, rollbacks and uninstalls
- Runs Helm install/upgrade in a specific order, taking into account the depends-on relationship - Offers extensive configuration options for automated remediation (rollback, uninstall, retry) on failed Helm install, upgrade or test actions
- Runs Helm install/upgrade in a specific order, taking into account the depends-on relationship defined in a set of `HelmRelease` objects
- Prunes Helm releases removed from cluster (garbage collection) - Prunes Helm releases removed from cluster (garbage collection)
- Reports Helm releases status (alerting provided by [notification-controller](../notification/controller.md)) - Reports Helm releases statuses (alerting provided by [notification-controller](../notification/controller.md))
Links: Links:

@ -55,12 +55,14 @@ Support for custom commands and generators executed by fluxd in a POSIX shell |
Flux v1 | Toolkit component driven "Flux v2" Flux v1 | Toolkit component driven "Flux v2"
---------------------------------- | ---------------------------------- ---------------------------------- | ----------------------------------
Declarative config in a single Helm custom resource | Declarative config through `HelmRepository`, `HelmChart` and `HelmRelease` custom resources Declarative config in a single Helm custom resource | Declarative config through `HelmRepository`, `GitRepository`, `HelmChart` and `HelmRelease` custom resources
Chart synchronisation embedded in the operator | Extensive release configuration options, and a reconciliation interval per source Chart synchronisation embedded in the operator | Extensive release configuration options, and a reconciliation interval per source
Support for fixed SemVer versions from Helm repositories | Support for SemVer ranges for `HelmChart` resources Support for fixed SemVer versions from Helm repositories | Support for SemVer ranges for `HelmChart` resources
Git repository synchronisation on a global interval | Planned support for charts from GitRepository sources Git repository synchronisation on a global interval | Planned support for charts from GitRepository sources
Limited observability via the status object of the HelmRelease resource | Better observability via the HelmRelease status object, Kubernetes events, and notifications Limited observability via the status object of the HelmRelease resource | Better observability via the HelmRelease status object, Kubernetes events, and notifications
Resource heavy, relatively slow | Better performance Resource heavy, relatively slow | Better performance
Chart changes from Git sources are determined from Git metadata | Chart changes must be accompanied by a version bump in `Chart.yaml` to produce a new artifact
Chart dependencies for charts from Git sources are downloaded by the operator | Chart dependencies must be committed to Git
#### Notifications, webhooks, observability #### Notifications, webhooks, observability

@ -4,7 +4,7 @@ The [helm-controller](../components/helm/controller.md) allows you to
declaratively manage Helm chart releases with Kubernetes manifests. declaratively manage Helm chart releases with Kubernetes manifests.
It makes use of the artifacts produced by the It makes use of the artifacts produced by the
[source-controller](../components/source/controller.md) from [source-controller](../components/source/controller.md) from
`HelmRepository` and `HelmChart` resources. `HelmRepository`, `GitRepository`, and `HelmChart` resources.
The helm-controller is part of the default toolkit installation. The helm-controller is part of the default toolkit installation.
## Prerequisites ## Prerequisites
@ -63,25 +63,26 @@ metadata:
spec: spec:
interval: 5m interval: 5m
chart: chart:
name: podinfo spec:
version: '^4.0.0' chart: podinfo
sourceRef: version: '4.0.x'
kind: HelmRepository sourceRef:
name: podinfo kind: HelmRepository
namespace: gitops-system name: podinfo
interval: 1m namespace: gitops-system
interval: 1m
values: values:
replicaCount: 2 replicaCount: 2
``` ```
The `chart.name` is the name of the chart as made available by the Helm The `chart.spec.chart` is the name of the chart as made available by
repository, and may not include any aliases. the Helm repository, and may not include any aliases.
The `chart.version` can be a fixed semver, or any semver range (i.e. The `chart.spec.version` can be a fixed semver, or any semver range
`>=4.0.0 <4.0.2`). (i.e. `>=4.0.0 <5.0.0`).
The `chart` values are used by the helm-controller as a template to The `chart.spec` values are used by the helm-controller as a template
create a new `HelmChart` resource in the same namespace as the to create a new `HelmChart` resource in the same namespace as the
`sourceRef`. The source-controller will then lookup the chart in the `sourceRef`. The source-controller will then lookup the chart in the
artifact of the referenced `HelmRepository`, fetch the chart, and make artifact of the referenced `HelmRepository`, fetch the chart, and make
it available as a `HelmChart` artifact to be used by the it available as a `HelmChart` artifact to be used by the

@ -136,11 +136,12 @@ metadata:
namespace: gitops-system namespace: gitops-system
spec: spec:
chart: chart:
name: sealed-secrets spec:
sourceRef: chart: sealed-secrets
kind: HelmRepository sourceRef:
name: stable kind: HelmRepository
version: "^1.10.0" name: stable
version: "1.10.x"
interval: 1h0m0s interval: 1h0m0s
releaseName: sealed-secrets releaseName: sealed-secrets
targetNamespace: gitops-system targetNamespace: gitops-system

Loading…
Cancel
Save