Install the EKS add-on with secure token handling
Deploy the Splunk Distribution of the OpenTelemetry Collector Amazon EKS add-on onto an Amazon EKS cluster without storing tokens in the EKS add-on configuration.
Secure installation is the recommended installation path.
- Subscribe to the add-on in AWS Marketplace.
In AWS Marketplace, make sure that:
-
You have sufficient permissions in your AWS account to activate this add-on.
-
You complete the subscription process in the AWS console. Go to the AWS Marketplace page to add the Splunk Distribution of the OpenTelemetry Collector Amazon EKS add-on to your AWS account.
-
- Meet the following prerequisites:
- Credentials
- Make sure you have credentials for Splunk Observability Cloud or the Splunk platform.
- Destination requirements
-
Splunk Observability Cloud
-
splunkObservability.accessToken. Your Splunk Observability Cloud organization access token. See Create and manage organization access tokens using Splunk Observability Cloud. -
splunkObservability.realm. Splunk realm to send telemetry data to. The default isus0. See Realms and endpoints in the developer portal.
The Splunk platform (Splunk Enterprise or Splunk Cloud Platform)
-
Splunk Enterprise 8.0 or higher.
-
At least one Splunk platform index to collect log data.
-
An HTTP Event Collector (HEC) token and endpoint. See Set up and use HTTP Event Collector in Splunk Web and Scale HTTP Event Collector.
-
- Prepare the add-on configuration.
Create a values.yaml file tailored to your Splunk setup. Use the following YAML samples and replace placeholder values with your configuration details.
CAUTION: For security reasons, don't include tokens or other sensitive data in the configuration file. EKS add-on configurations are exposed in the EKS web console.Note: The EKS add-on accepts only configuration fields included in the published AWS configuration schema. Some options available in the regular Helm chart are unavailable in the EKS add-on.Retrieve the schema for a selected add-on version by running the following command:
BASHaws eks describe-addon-configuration \ --addon-name splunk_splunk-otel-collector-chart \ --addon-version your-addon-versionNote: For more configuration information, see Install the Collector for Kubernetes using Helm.- Splunk Observability Cloud
-
YAML
splunkObservability: accessToken: "" realm: your-splunk-realm clusterName: your-eks-cluster-name cloudProvider: aws distribution: eks secret: create: false name: splunk-otel-collector validateSecret: false - Splunk platform
-
Replace the endpoint with a Splunk HEC endpoint that is reachable from the EKS worker nodes.
Set
splunkPlatform.tokento an empty string so the HEC token is read from the Kubernetes Secret instead of being stored in the EKS add-on configuration.YAMLsplunkPlatform: endpoint: https://your-splunk-host:8088/services/collector/event token: "" splunkObservability: accessToken: "" realm: "" clusterName: your-eks-cluster-name cloudProvider: aws distribution: eks secret: create: false name: splunk-otel-collector validateSecret: false
- Create the
splunk-monitoringnamespace and Kubernetes Secret.Note: The predefined namespace for this add-on issplunk-monitoring. Amazon EKS makes this namespace available when the add-on is installed. To create the Secret before the Collector workloads start, create the namespace explicitly before installing the add-on. Alternatively, you can allow EKS to create the namespace by installing the add-on first and then creating the Secret. The Collector pods might remain temporarily unavailable until the Secret exists.Apply one of the following manifests before you install the add-on:
- Splunk Observability Cloud
-
YAML
apiVersion: v1 kind: Namespace metadata: name: splunk-monitoring --- apiVersion: v1 kind: Secret metadata: name: splunk-otel-collector namespace: splunk-monitoring type: Opaque stringData: splunk_observability_access_token: your-splunk-access-token - Splunk platform
-
YAML
apiVersion: v1 kind: Namespace metadata: name: splunk-monitoring --- apiVersion: v1 kind: Secret metadata: name: splunk-otel-collector namespace: splunk-monitoring type: Opaque stringData: splunk_platform_hec_token: your-hec-token
Save the selected manifest as splunk-otel-collector-secret.yaml, and then run the following command:
BASHkubectl apply -f splunk-otel-collector-secret.yaml - Install the EKS add-on using the prepared configuration.
To install the add-on by using the AWS CLI, run the following command:
BASHaws eks create-addon \ --cluster-name your-eks-cluster-name \ --addon-name splunk_splunk-otel-collector-chart \ --configuration-values file://values.yamlIn the Amazon EKS console, select the Splunk add-on and a compatible version. Enter the equivalent contents of values.yaml under the optional configuration settings before creating the add-on.
- Verify the add-on and Collector pods.
Check that the add-on is active and the Collector pods are running.
BASHaws eks describe-addon \ --cluster-name your-eks-cluster-name \ --addon-name splunk_splunk-otel-collector-chart kubectl get pods -n splunk-monitoring