---
title: "Kubernetes OpenTelemetry Operator | OpenTelemetry documentation"
description: "Set up the Kubernetes OpenTelemetry Operator to use with Grafana OpenTelemetry distributions for Java and .NET and Grafana Alloy."
---

# Kubernetes OpenTelemetry Operator

When you deploy your application in Kubernetes, you can use the [OpenTelemetry Operator](https://opentelemetry.io/docs/kubernetes/operator/) to:

1. Simplify how you deploy and manage OpenTelemetry components in Kubernetes.
2. Inject OpenTelemetry instrumentation into Kubernetes workloads and send data to an OTLP endpoint.

## Set up

Follow the [OpenTelemetry Operator documentation](https://opentelemetry.io/docs/kubernetes/operator/automatic/) to set up the OpenTelemetry Operator in your Kubernetes cluster.

## Kubernetes Monitoring

We recommend starting with [Kubernetes (Alloy)](../../collector/grafana-alloy-kubernetes/) to monitor your Kubernetes cluster.

Skip the optional step to [install the OpenTelemetry Collector](https://opentelemetry.io/docs/kubernetes/operator/automatic/#create-an-opentelemetry-collector-optional) and use the OTLP endpoint provided by the Kubernetes Alloy configuration.

## Grafana OpenTelemetry SDK distributions

You can use custom Docker images of Grafana OpenTelemetry SDK distributions to instrument applications with the OpenTelemetry Operator.

The [OpenTelemetry Operator documentation](https://opentelemetry.io/docs/kubernetes/operator/automatic/#configure-automatic-instrumentation) lists all upstream and community-supported languages.

### Java example

The following example shows how to use the [Grafana Labs distribution of the OpenTelemetry SDK for Java (JVM)](../grafana-java/) with the OpenTelemetry Operator.

Follow the OpenTelemetry Operator [Java documentation](https://opentelemetry.io/docs/kubernetes/operator/automatic/#java) and add the following to the Kubernetes `Instrumentation` manifest to use the Grafana Java SDK:

YAML ![Copy code to clipboard](/media/images/icons/icon-copy-small-2.svg) Copy

```yaml
spec:
  java:
    image: us-docker.pkg.dev/grafanalabs-global/docker-grafana-opentelemetry-java-prod/grafana-opentelemetry-java:2.3.0-beta.1
  exporter:
    ..
```

If you use the OpenTelemetry Operator [Helm chart](https://opentelemetry.io/docs/kubernetes/operator/automatic/#helm-chart), set the image using Helm instead of manually editing the `Instrumentation` manifest.

shell ![Copy code to clipboard](/media/images/icons/icon-copy-small-2.svg) Copy

```shell
helm upgrade opentelemetry-operator open-telemetry/opentelemetry-operator --set manager.autoInstrumentationImage.java.repository=us-docker.pkg.dev/grafanalabs-global/docker-grafana-opentelemetry-java-prod/grafana-opentelemetry-java,manager.autoInstrumentationImage.java.tag=2.3.0-beta.1
```

> Note
> 
> The docker tag `2.3.0-beta.1` matches the version on the [release page](https://github.com/grafana/grafana-opentelemetry-java/releases) with the `v` prefix removed.
