No description
  • Go 95.8%
  • Shell 2.3%
  • Dockerfile 1.3%
  • Makefile 0.6%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Brad Davidson 09ccacdb71 Wire up spec.forceConflicts and add test
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2026-07-22 01:40:36 -07:00
.github Bump the action-deps group with 11 updates (#333) 2026-07-02 09:59:54 -07:00
doc Add "retry" failure policy value 2026-07-22 01:40:36 -07:00
manifests Add DEFAULT_JOB_IMAGE to example deployment manifest 2025-12-05 14:00:22 -08:00
pkg Wire up spec.forceConflicts and add test 2026-07-22 01:40:36 -07:00
scripts Fix old job replacement 2026-07-16 16:15:22 -07:00
test Wire up spec.forceConflicts and add test 2026-07-22 01:40:36 -07:00
updatecli chore: Update key "version" from file "/tmp/updatecli/github/k3s-io/h... 2023-05-05 18:10:57 +00:00
.dockerignore initial commit 2019-04-29 14:24:59 -07:00
.gitignore Remove Dapper from build system (#263) 2025-02-04 12:35:35 -08:00
.golangci.yml Fix linter errors 2026-02-17 11:37:00 -08:00
crd-ref-docs.yaml Rework CRD generation to add docs and kubectl explain support 2025-07-03 10:42:17 -07:00
Dockerfile Run all go commands with cache 2026-07-16 16:15:22 -07:00
go.mod Bump go.opentelemetry.io/otel from 1.36.0 to 1.41.0 (#330) 2026-07-02 10:05:33 -07:00
go.sum Bump go.opentelemetry.io/otel from 1.36.0 to 1.41.0 (#330) 2026-07-02 10:05:33 -07:00
kustomization.yaml Fix manifest RBAC and namespaces 2025-03-20 12:03:33 -07:00
LICENSE initial commit 2019-04-29 14:24:59 -07:00
main.go Add config helpers 2026-06-24 16:03:12 -07:00
Makefile Improve the building steps and add a target for new CRDs (#291) 2025-11-10 19:02:23 +01:00
README.md Improve the building steps and add a target for new CRDs (#291) 2025-11-10 19:02:23 +01:00

helm-controller

A simple way to manage helm charts with Custom Resource Definitions in k8s.

Manifests and Deploying

The ./manifests folder contains useful YAML manifests to use for deploying and developing the Helm Controller. However, we recommend using the deploy-cluster-scoped.yaml or deploy-namespaced.yaml manifests included in the releases. The YAML might need some modifications for your environment so read below for Namespaced vs Cluster deployments and how to use them properly.

Namespaced Deploys

Use the deploy-namespaced.yaml to create a namespace and add the Helm Controller and CRD to that namespace locking down the Helm Controller to only see changes to CRDs within that namespace. This is defaulted to helm-controller so update the YAML to your needs before running kubectl create

Cluster Scoped Deploys

If you'd like your helm controller to watch the entire cluster for HelmChart CRD changes use the deploy-cluster-scoped.yaml deploy manifest. By default it will add the helm-controller to the kube-system so update metadata.namespace for your needs.

API Documentation

Autogenerated API docs for helm.cattle.io/v1 HelmChart and HelmChartConfig are available at doc/helmchart.md

Uninstalling

To remove the Helm Controller run kubectl delete and pass the deployment YAML used using to create the Deployment -f parameter.

Developing and Building

The Helm Controller is easy to get running locally, follow the instructions for your needs and requires a running k8s server + CRDs etc. When you have a working k8s cluster, you can apply the manifests inside ./pkg/crds/yaml/generated/ to create the CRD and ./manifests/example-helmchart.yaml which runs the stable/traefik helm chart.

Build

Run make build to build the binary and, optionally, generate new CRDs if the API changed. We recommend just running make as the default target will also perform validation and testing.

Running it locally

Building and running natively will start a daemon which will watch a local k8s API. See Manifests section above about how to create the CRD and Objects using the provided manifests.

go build -o ./bin/helm-controller
./bin/helm-controller --kubeconfig $HOME/.kube/config

Running it on k8s

Use the deploy-cluster-scoped.yaml or deploy-namespaced.yaml manifests in the assets of each release to run the helm-controller in Kubernetes.

Options and Usage

Use ./bin/helm-controller help to get full usage details. The outside of a k8s Pod the most important options are --kubeconfig or --masterurl or it will not run. All options have corresponding ENV variables you could use.

Testing/Validating

make test make validate

License

Copyright (c) 2019 Rancher Labs, Inc.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.