helm-charts icon indicating copy to clipboard operation
helm-charts copied to clipboard

Add namespace override to community-operator

Open bbergquist0930 opened this issue 7 months ago • 1 comments

All Submissions:

  • [x] Have you opened an Issue before filing this PR?
  • [x] Have you signed our CLA?
  • [x] Have you checked to ensure there aren't other open Pull Requests for the same update/change?
  • [x] Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if such).

Closes #276

This allows the community-operator to be used as a subchart provided that #283 is merged in. This adds in a _helpers.tpl to help support the namespace override and creation. Also changes are made to set the Helm labels on the resources so that Helm knows about them. This is useful to support multiple instances of the community-operator chart in separate namespaces.

This completes the namespace support of the operator. The operator should be able to be installed in the default namespace or in a custom namespace.

Usages

Install in the default chart namespace and the default Kubernetes namespace

helm install community-operator <chart>

Install in a custom chart namespace and the default Kubernetes namespace

helm install community-operator <chart> --namespace mongodb-chart --create-namespace

Install in the default chart namespace and a custom Kubernetes namespace

helm install community-operator <chart> --set operator.namespace.create=true --set operator.namespace.name=mongodb

Install in a custom chart namespace and a custom Kubernetes namespace

helm install community-operator <chart> --namespace mongodb-chart --create-namespace --set operator.namespace.create=true --set operator.namespace.name=mongodb

bbergquist0930 avatar Nov 19 '23 14:11 bbergquist0930