mongodb

by joaquinito2051

Helm chartv13.3.1App 6.0.2

MongoDB(R) is a relational open source NoSQL database. Easy to use, it stores data in JSON-like documents. Automated scalability and high-performance. Ideal for developing cloud native applications.

About this chart

MongoDB(R) packaged by Bitnami

MongoDB(R) is a relational open source NoSQL database. Easy to use, it stores data in JSON-like documents. Automated scalability and high-performance. Ideal for developing cloud native applications.

Overview of MongoDB®

Disclaimer: The respective trademarks mentioned in the offering are owned by the respective companies. We do not provide a commercial license for any of these products. This listing has an open-source license. MongoDB(R) is run and maintained by MongoDB, which is a completely separate project from Bitnami.

Azure-ready Charts with Containers from marketplace.azurecr.io

This Helm Chart has been configured to pull the Container Images from the Azure Marketplace Public Repository. The following command allows you to download and install all the charts from this repository.

$ helm repo add bitnami-azure https://marketplace.azurecr.io/helm/v1/repo

TL;DR

$ helm repo add my-repo https://charts.bitnami.com/bitnami
$ helm install my-release my-repo/mongodb

Introduction

This chart bootstraps a MongoDB(®) deployment on a Kubernetes cluster using the Helm package manager.

Bitnami charts can be used with Kubeapps for deployment and management of Helm Charts in clusters.

Prerequisites

  • Kubernetes 1.19+
  • Helm 3.2.0+
  • PV provisioner support in the underlying infrastructure

Installing the Chart

To install the chart with the release name my-release:

$ helm install my-release my-repo/mongodb

The command deploys MongoDB(®) on the Kubernetes cluster in the default configuration. The Parameters section lists the parameters that can be configured during installation.

Tip: List all releases using helm list

Uninstalling the Chart

To uninstall/delete the my-release deployment:

$ helm delete my-release

The command removes all the Kubernetes components associated with the chart and deletes the release.

Architecture

This chart allows installing MongoDB(®) using two different architecture setups: standalone or replicaset. Use the architecture parameter to choose the one to use:

architecture="standalone"
architecture="replicaset"

Refer to the chart documentation for more information on each of these architectures.

Parameters

Global parameters

NameDescriptionValue
global.imageRegistryGlobal Docker image registry""
global.imagePullSecretsGlobal Docker registry secret names as an array[]
global.storageClassGlobal StorageClass for Persistent Volume(s)""
global.namespaceOverrideOverride the namespace for resource deployed by the chart, but can itself be overridden by the local namespaceOverride""

Common parameters

NameDescriptionValue
nameOverrideString to partially override mongodb.fullname template (will maintain the release name)""
fullnameOverrideString to fully override mongodb.fullname template""
namespaceOverrideString to fully override common.names.namespace""
kubeVersionForce target Kubernetes version (using Helm capabilities if not set)""
clusterDomainDefault Kubernetes cluster domaincluster.local
extraDeployArray of extra objects to deploy with the release[]
commonLabelsAdd labels to all the deployed resources (sub-charts are not considered). Evaluated as a template{}
commonAnnotationsCommon annotations to add to all Mongo resources (sub-charts are not considered). Evaluated as a template{}
diagnosticMode.enabledEnable diagnostic mode (all probes will be disabled and the command will be overridden)false
diagnosticMode.commandCommand to override all containers in the deployment["sleep"]
diagnosticMode.argsArgs to override all containers in the deployment["infinity"]

MongoDB(®) parameters

NameDescriptionValue
image.registryMongoDB(®) image registrydocker.io
image.repositoryMongoDB(®) image registrybitnami/mongodb
image.tagMongoDB(®) image tag (immutable tags are recommended)6.0.2-debian-11-r11
image.digestMongoDB(®) image digest in the way sha256:aa.... Please note this parameter, if set, will override the tag""
image.pullPolicyMongoDB(®) image pull policyIfNotPresent
image.pullSecretsSpecify docker-registry secret names as an array[]
image.debugSet to true if you would like to see extra information on logsfalse
schedulerNameName of the scheduler (other than default) to dispatch pods""
architectureMongoDB(®) architecture (standalone or replicaset)standalone
useStatefulSetSet to true to use a StatefulSet instead of a Deployment (only when architecture=standalone)false
auth.enabledEnable authenticationtrue
auth.rootUserMongoDB(®) root userroot
auth.rootPasswordMongoDB(®) root password""
auth.usernamesList of custom users to be created during the initialization[]
auth.passwordsList of passwords for the custom users set at auth.usernames[]
auth.databasesList of custom databases to be created during the initialization[]
auth.usernameDEPRECATED: use auth.usernames instead""
auth.passwordDEPRECATED: use auth.passwords instead""
auth.databaseDEPRECATED: use auth.databases instead""
auth.replicaSetKeyKey used for authentication in the replicaset (only when architecture=replicaset)""
auth.existingSecretExisting secret with MongoDB(®) credentials (keys: mongodb-passwords, mongodb-root-password, mongodb-metrics-password, mongodb-replica-set-key)""
tls.enabledEnable MongoDB(®) TLS support between nodes in the cluster as well as between mongo clients and nodesfalse
tls.autoGeneratedGenerate a custom CA and self-signed certificatestrue
tls.existingSecretExisting secret with TLS certificates (keys: mongodb-ca-cert, mongodb-ca-key)""
tls.caCertCustom CA certificated (base64 encoded)""
tls.caKeyCA certificate private key (base64 encoded)""
tls.standalone.existingSecretExisting secret with TLS certificates (tls.key, tls.crt, ca.crt).""
tls.replicaset.existingSecretsArray of existing secrets with TLS certificates (tls.key, tls.crt, ca.crt).[]
tls.hidden.existingSecretsArray of existing secrets with TLS certificates (tls.key, tls.crt, ca.crt).[]
tls.arbiter.existingSecretExisting secret with TLS certificates (tls.key, tls.crt, ca.crt).""
tls.image.registryInit container TLS certs setup image registrydocker.io
tls.image.repositoryInit container TLS certs setup image repositorybitnami/nginx
tls.image.tagInit container TLS certs setup image tag (immutable tags are recommended)1.23.2-debian-11-r3
tls.image.digestInit container TLS certs setup image digest in the way sha256:aa.... Please note this parameter, if set, will override the tag""
tls.image.pullPolicyInit container TLS certs setup image pull policyIfNotPresent
tls.image.pullSecretsInit container TLS certs specify docker-registry secret names as an array

Deploy mongodb with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has mongodb on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.

  1. Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
  2. Place the chartmongodb is pinned at v13.3.1 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
  3. ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below
opentenant validate opentenant.yaml
terraform init && terraform apply