Skip to content

Commit

Permalink
Port PR 4488 to Serverless - adding k8s-otel quickstart guide (#4589)
Browse files Browse the repository at this point in the history
* k8s-otel quickstart added to serverless
* minor fixes in stateful
  • Loading branch information
eedugon authored Nov 29, 2024
1 parent 64b89f9 commit 58c98f8
Show file tree
Hide file tree
Showing 7 changed files with 72 additions and 3 deletions.
3 changes: 2 additions & 1 deletion docs/en/observability/observability-get-started.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,8 @@ Follow the steps in these guides to get started quickly:

* <<quickstart-monitor-hosts-with-elastic-agent>>
* <<monitor-k8s-logs-metrics-with-elastic-agent>>

* <<monitor-k8s-otel-edot>>
* <<collect-data-with-aws-firehose>>

[discrete]
=== Get started with other features
Expand Down
4 changes: 2 additions & 2 deletions docs/en/observability/quickstarts/monitor-k8s-otel.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ image::images/quickstart-k8s-otel-dashboard.png[Kubernetes overview dashboard]
[discrete]
== Troubleshooting and more

* For troubleshooting deployment and installation, refer to https://github.com/elastic/opentelemetry/tree/main/docs/kubernetes/operator#installation-verification[installation verification].
* To troubleshoot deployment and installation, refer to https://github.com/elastic/opentelemetry/tree/main/docs/kubernetes/operator#installation-verification[installation verification].
* For application instrumentation details, refer to https://github.com/elastic/opentelemetry/blob/main/docs/kubernetes/operator/instrumenting-applications.md[Instrumenting applications with EDOT SDKs on Kubernetes].
* For customizing the configuration, refer to https://github.com/elastic/opentelemetry/tree/main/docs/kubernetes/operator#custom-configuration[custom configuration].
* To customize the configuration, refer to https://github.com/elastic/opentelemetry/tree/main/docs/kubernetes/operator#custom-configuration[custom configuration].
* Refer to <<observability-introduction>> for a description of other useful features.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions docs/en/serverless/index.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ include::./projects/create-an-observability-project.asciidoc[leveloffset=+3]
// Quickstarts
include::./quickstarts/monitor-hosts-with-elastic-agent.asciidoc[leveloffset=+3]
include::./quickstarts/k8s-logs-metrics.asciidoc[leveloffset=+3]
include::./quickstarts/monitor-k8s-otel.asciidoc[leveloffset=+3]
include::./quickstarts/collect-data-with-aws-firehose.asciidoc[leveloffset=+3]

// Dashboards
Expand Down
1 change: 1 addition & 0 deletions docs/en/serverless/observability-get-started.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ Follow the steps in these guides to get started quickly:

* <<observability-quickstarts-monitor-hosts-with-elastic-agent>>
* <<observability-quickstarts-k8s-logs-metrics>>
* <<monitor-k8s-otel-edot>>
* <<collect-data-with-aws-firehose>>

[discrete]
Expand Down
66 changes: 66 additions & 0 deletions docs/en/serverless/quickstarts/monitor-k8s-otel.asciidoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
[[monitor-k8s-otel-edot]]
= Quickstart: Unified Kubernetes Observability with Elastic Distributions of OpenTelemetry (EDOT)

preview::[]

In this quickstart guide, you'll learn how to send Kubernetes logs, metrics, and application traces to Elasticsearch, using the https://github.com/open-telemetry/opentelemetry-operator/[OpenTelemetry Operator] to orchestrate https://github.com/elastic/opentelemetry/tree/main[Elastic Distributions of OpenTelemetry] (EDOT) Collectors and SDK instances.

All the components will be deployed through the https://github.com/open-telemetry/opentelemetry-helm-charts/tree/main/charts/opentelemetry-kube-stack[opentelemetry-kube-stack] helm chart. They include:

* https://github.com/open-telemetry/opentelemetry-operator/[OpenTelemetry Operator].
* `DaemonSet` EDOT Collector configured for node level metrics.
* `Deployment` EDOT Collector configured for cluster level metrics.
* `Instrumentation` object for applications https://opentelemetry.io/docs/kubernetes/operator/automatic/[auto-instrumentation].

For a more detailed description of the components and advanced configuration, refer to the https://github.com/elastic/opentelemetry/blob/main/docs/kubernetes/operator/README.md[elastic/opentelemetry] GitHub repository.

[discrete]
== Prerequisites

* An {obs-serverless} project. To learn more, refer to <<observability-create-an-observability-project>>.
* A running Kubernetes cluster (v1.23 or newer).
* https://kubernetes.io/docs/reference/kubectl/[Kubectl].
* https://helm.sh/docs/intro/install/[Helm].
* (optional) https://cert-manager.io/docs/installation/[Cert-manager], if you opt for automatic generation and renewal of TLS certificates.

[discrete]
== Collect your data

. <<observability-create-an-observability-project,Create a new {obs-serverless} project>>, or open an existing one.
. In your {obs-serverless} project, go to **Add Data**.
. Under **What do you want to monitor?** select **Kubernetes**, and then select **OpenTelemetry: Full Observability**.
+
[role="screenshot"]
image::images/quickstart-k8s-otel-entry-point.png[Kubernetes-OTel entry point]

. Follow the on-screen instructions to install all needed components.
+
[NOTE]
====
The default installation deploys the OpenTelemetry Operator with a self-signed TLS certificate valid for 365 days. This certificate **won't be renewed** unless the Helm Chart release is manually updated. Refer to the https://github.com/elastic/opentelemetry/blob/main/docs/kubernetes/operator/README.md#cert-manager[cert-manager integrated installation] guide to enable automatic certificate generation and renewal using https://cert-manager.io/docs/installation/[cert-manager].
====
+
Deploy the OpenTelemetry Operator and EDOT Collectors using the kube-stack Helm chart with the provided `values.yaml` file. You will run a few commands to:
+
* Add the helm chart repository needed for the installation.
* Create a namespace.
* Create a secret with an API Key and the {es} endpoint to be used by the collectors.
* Install the `opentelemetry-kube-stack` helm chart with the provided `values.yaml`.
* Optionally, for instrumenting applications, apply the corresponding `annotations` as shown in {kib}.

[discrete]
== Visualize your data

After installation is complete and all relevant data is flowing into Elastic,
the **Visualize your data** section provides a link to the *[OTEL][Metrics Kubernetes]Cluster Overview* dashboard used to monitor the health of the cluster.

[role="screenshot"]
image::images/quickstart-k8s-otel-dashboard.png[Kubernetes overview dashboard]

[discrete]
== Troubleshooting and more

* To troubleshoot deployment and installation, refer to https://github.com/elastic/opentelemetry/tree/main/docs/kubernetes/operator#installation-verification[installation verification].
* For application instrumentation details, refer to https://github.com/elastic/opentelemetry/blob/main/docs/kubernetes/operator/instrumenting-applications.md[Instrumenting applications with EDOT SDKs on Kubernetes].
* To customize the configuration, refer to https://github.com/elastic/opentelemetry/tree/main/docs/kubernetes/operator#custom-configuration[custom configuration].
* Refer to <<observability-serverless-observability-overview>> for a description of other useful features.

0 comments on commit 58c98f8

Please sign in to comment.