Skip to content

Enable agent auto-install in EKS add-on wrapper chart#2754

Open
gpalmz wants to merge 9 commits intoDataDog:mainfrom
gpalmz:grant.palmer/eks-addon-agent-auto-install
Open

Enable agent auto-install in EKS add-on wrapper chart#2754
gpalmz wants to merge 9 commits intoDataDog:mainfrom
gpalmz:grant.palmer/eks-addon-agent-auto-install

Conversation

@gpalmz
Copy link

@gpalmz gpalmz commented Mar 12, 2026

Summary

  • Enables the installAgents feature in the operator-eks-addon wrapper chart so agents are automatically deployed after the EKS add-on installs the operator
  • Adds installAgents, apiKey, and appKey to the AWS Marketplace configuration schema
  • Points the agent-install Job image to the Marketplace ECR registry
  • Documents the automatic agent installation behavior in the README

Details

The installAgents feature (Job, RBAC, ConfigMap templates) lives in the datadog-operator subchart in helm-charts (DataDog/helm-charts#2476). This PR configures the EKS add-on wrapper to enable it by default:

values.yaml

  • installAgents: true — agents install automatically
  • agentInstallJob.image.repository — points to Marketplace ECR (709825985650.dkr.ecr.us-east-1.amazonaws.com/datadog/kubectl) instead of Docker Hub, since private/air-gapped EKS clusters may not have external egress

aws_mp_configuration_schema.json

  • installAgents (boolean, default true) — exposed for EKS Console / CLI / CloudFormation
  • apiKey and appKey (strings) — credential fields for add-on configuration
  • agentInstallJob.image is intentionally not exposed — all install-time images must come from the Marketplace ECR
  • apiKey is intentionally not required at schema level — draft-04 JSON Schema has no conditional required, and the subchart already validates at template time when installAgents is true

README.md

  • Documents automatic agent installation and how to disable it
  • Adds crane copy command for the kubectl image under "Pushing Container Images"

No template duplication is needed — the wrapper passes values through to the subchart via Helm's dependency system.

Dependencies

Test plan

  • After helm-charts PR merges and subchart is released, update dependency version in Chart.yaml and bump wrapper chart version
  • helm dependency build in marketplaces/charts/operator-eks-addon/
  • helm template test . --set datadog-operator.apiKey=test123 — verify agent-install Job, ConfigMap, RBAC, and operator Deployment all render
  • helm template test . --set datadog-operator.apiKey=test123 --set datadog-operator.installAgents=false — verify no agent-install resources
  • helm template test . (no apiKey) — verify template error about missing API key
  • Validate on Kind cluster with public registry swap

🤖 Generated with Claude Code

Configure the operator-eks-addon wrapper to enable the installAgents
feature from the datadog-operator subchart, so agents are automatically
deployed after the operator is installed via the EKS add-on.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@gpalmz gpalmz requested a review from a team March 12, 2026 22:36
@gpalmz gpalmz requested review from a team as code owners March 12, 2026 22:36
Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: f2c05b9504

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

The EKS add-on requires all images to be available in the Marketplace
ECR. Using bitnami/kubectl from Docker Hub would cause ImagePullBackOff
in private-cluster setups without egress. Also expose agentInstallJob
image config in the AWS Marketplace schema so it can be overridden.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@gpalmz
Copy link
Author

gpalmz commented Mar 12, 2026

@codex review

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 2cc510a3b4

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

gpalmz and others added 2 commits March 12, 2026 18:58
With installAgents defaulting to true, omitting the API key would pass
schema validation but fail at hook runtime. Making apiKey required in
the schema surfaces the error in the EKS console before installation.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The wrapper still pins datadog-operator to 2.18.1 which does not have
the installAgents feature. Bumping to 0.1.25 now would advertise a
capability that the subchart cannot deliver. The version bump and
version table entry should be added when the dependency is updated.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@gpalmz
Copy link
Author

gpalmz commented Mar 12, 2026

@codex review

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 059482fcc1

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Draft-04 JSON Schema has no conditional required support, so this
blocked operator-only deployments with installAgents=false. The
subchart already validates at template time that an API key is set
when installAgents is true.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@gpalmz
Copy link
Author

gpalmz commented Mar 12, 2026

@codex review

@chatgpt-codex-connector
Copy link

Codex Review: Didn't find any major issues. Swish!

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@codecov-commenter
Copy link

codecov-commenter commented Mar 12, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 38.78%. Comparing base (40e907c) to head (bbce017).

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #2754   +/-   ##
=======================================
  Coverage   38.78%   38.78%           
=======================================
  Files         309      309           
  Lines       26839    26839           
=======================================
  Hits        10409    10409           
  Misses      15650    15650           
  Partials      780      780           
Flag Coverage Δ
unittests 38.78% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 40e907c...bbce017. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

gpalmz and others added 4 commits March 16, 2026 16:01
All images must be pulled from the EKS Marketplace ECR at install time.
Exposing the image repository in the schema would let users override it
to an external registry, breaking private-cluster installs. The image
is pinned in values.yaml and should not be user-configurable.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The hook Job downloads the agent config at install time, which requires
internet egress. Private/air-gapped EKS clusters would fail. This
should not be user-configurable in the Marketplace; the helm-charts
subchart needs to embed the default config instead of downloading it.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The helm-charts PR was updated to embed the default agent config in a
ConfigMap instead of downloading it at runtime. agentConfigUrl no longer
exists in the subchart. Also updated README to reflect that the Job is
no longer a Helm hook and config is bundled, not fetched.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants