Skip to content

GIT-2: MongoDB addon (MongoDB Controllers for Kubernetes) - #37

Merged
noels merged 1 commit into
mainfrom
GIT-2
Oct 3, 2026
Merged

noels merged 1 commit into
mainfrom
GIT-2

Conversation

@noels

@noels noels commented Oct 3, 2026 •

Copy link
Copy Markdown
Member

Jira: GIT-2

What

New addon addons-mongodb: the mongodb-kubernetes operator chart 1.13.0 (MongoDB Controllers for Kubernetes, the successor to the deprecated community-operator), from https://mongodb.github.io/helm-charts.

  • Enabled per cluster with the enable_mongodb label → namespace mongodb (CreateNamespace=true).
  • preserveResourcesOnDeletion: true: the chart ships the CRDs, so a cascading delete would remove every MongoDBCommunity → StatefulSet → PVC.
  • Standard layering: environments/default → environments/<env> → clusters/<cluster> for addons/mongodb-kubernetes/values.yaml. Index-1 chart source, so the private overlay patches apply unchanged.
  • Defaults keep the chart's single-namespace watch. values.yaml documents the comma-separated operator.watchNamespace override. It also says why not "*": the chart then creates the database ServiceAccounts only in the operator namespace.
  • Commented-out reference setup: resources/kustomization.yaml (resources: [], Prune=false,Delete=false, sync-wave 10) plus mongodbcommunity-replicaset.example.yaml (3-member replica set, SCRAM user, password Secret from SOPS/ESO).
  • No ignoreDifferences: the operator registers its ValidatingWebhookConfiguration at runtime, outside the chart.

Checks

  • yamllint clean. kustomize build passes for the resources dir, both as committed and with the example enabled.
  • The example CR validates against the chart 1.13.0 mongodbcommunity CRD schema (jsonschema).
  • helm template: the default watches only the release namespace; watchNamespace: mongodb,my-app creates the SAs/Roles in both.
  • Not deployed to a cluster yet.

Depends on

SilexConsulting/gitops-control-plane GIT-2 (allowed_addons += mongodb), so the Terraform precondition accepts enable_mongodb.

Adds addons-mongodb: the mongodb-kubernetes operator chart 1.13.0 (successor
to the deprecated community-operator), enabled per cluster with
enable_mongodb, installed into the mongodb namespace.

- preserveResourcesOnDeletion: the chart ships the CRDs, so a cascading
  delete would take every MongoDBCommunity and its data with it.
- Defaults keep the chart's single-namespace watch; values.yaml documents
  the comma-separated watchNamespace override (and why not "*").
- Commented-out reference setup: resources/ with an example 3-member
  MongoDBCommunity replica set (validated against the chart's CRD schema).
@noels
noels marked this pull request as ready for review October 3, 2026 16:15
@noels
noels merged commit 0215fca into main Oct 3, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant