MongoDB Exporter

Prometheus exporter for MongoDB database metrics and monitoring.

Requirements

Name

Version

terraform

>= 1.0

kubernetes

>= 2.21.1

Providers

Name

Version

kubernetes

>= 2.21.1

Modules

Name

Source

Version

mongodb_aggregator

../../../../utils/aggregator

n/a

Resources

Name

Type

kubernetes_deployment.mongodb_exporter

resource

kubernetes_service.mongodb_exporter_service

resource

Inputs

Name

Description

Type

Default

Required

disable_diagnostic_data

When working with a sharded on-premise MongoDB deployment, this flag works around the exporter crashing (but exports less metrics)

bool

false

no

docker_image

Docker image for MongoDB metrics exporter

object({
image = string
tag = string
image_pull_secrets = string
})

n/a

yes

force_split_cluster

Used when working with mongodb+srv URIs (this is typically the case with Atlas-managed MongoDB), it adds the ‘–split-cluster’ flag to the exporter flags. You can force this to be on.

bool

false

no

mongodb_modules

MongoDB modules to use when building the exporter (assumes only one is actually active)

any

n/a

yes

namespace

Kubernetes namespace to use for this resource

string

n/a

yes

Outputs

Name

Description

namespace

Namespace of the MongoDB metrics exporter

url

Url of the MongoDB Metrics exporter