From c99d80ca4e28818f951ed287c775ab1fce76e92d Mon Sep 17 00:00:00 2001 From: David Hope Date: Wed, 9 Oct 2024 06:01:10 -0400 Subject: [PATCH] change the authentication method to work with Elastic Serverless (#90) * Update README.md * Update deployment.yaml * Update otelcol-elastic-config-extras.yaml --- .github/README.md | 2 +- kubernetes/elastic-helm/deployment.yaml | 2 +- src/otelcollector/otelcol-elastic-config-extras.yaml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/README.md b/.github/README.md index 95dabf3ec1..46dccc866f 100644 --- a/.github/README.md +++ b/.github/README.md @@ -37,7 +37,7 @@ Additionally, the OpenTelemetry Contrib collector has also been changed to the [ ``` Don't forget to replace - `YOUR_APM_ENDPOINT_WITHOUT_HTTPS_PREFIX`: your Elastic APM endpoint (*without* `https://` prefix) that *must* also include the port (example: `1234567.apm.us-west2.gcp.elastic-cloud.com:443`). - - `YOUR_APM_SECRET_TOKEN`: your Elastic APM secret token + - `YOUR_APM_SECRET_TOKEN`: your Elastic APM secret token, include the Bearer or ApiKey but not the "Authorization=" part e.g. Bearer XXXXXX or ApiKey XXXXX 1. Execute the following commands to deploy the OpenTelemetry demo to your Kubernetes cluster: ``` # clone this repository diff --git a/kubernetes/elastic-helm/deployment.yaml b/kubernetes/elastic-helm/deployment.yaml index 7c0867cd44..4ea2956999 100644 --- a/kubernetes/elastic-helm/deployment.yaml +++ b/kubernetes/elastic-helm/deployment.yaml @@ -71,7 +71,7 @@ opentelemetry-collector: endpoint: ${env:ELASTIC_APM_ENDPOINT} compression: none headers: - Authorization: Bearer ${env:ELASTIC_APM_SECRET_TOKEN} + Authorization: ${env:ELASTIC_APM_SECRET_TOKEN} processors: batch: {} resource: diff --git a/src/otelcollector/otelcol-elastic-config-extras.yaml b/src/otelcollector/otelcol-elastic-config-extras.yaml index 530d47ad15..fe26fbc1f3 100644 --- a/src/otelcollector/otelcol-elastic-config-extras.yaml +++ b/src/otelcollector/otelcol-elastic-config-extras.yaml @@ -4,7 +4,7 @@ exporters: endpoint: "YOUR_APM_ENDPOINT_WITHOUT_HTTPS_PREFIX" compression: none headers: - Authorization: "Bearer YOUR_APM_SECRET_TOKEN" + Authorization: "YOUR_APM_SECRET_TOKEN" service: pipelines: