Skip to content

[9.4] (backport #17403) Fix typos in install help, enroll error and Helm values comments - #17489

Merged
swiatekm merged 1 commit into
9.4from
mergify/bp/9.4/pr-17403
Oct 28, 2026
Merged

swiatekm merged 1 commit into
9.4from
mergify/bp/9.4/pr-17403

Conversation

@mergify

@mergify mergify Bot commented Oct 23, 2026

Copy link
Copy Markdown
Contributor

What does this PR do?

Fixes the remaining items of #14578 — items 1, 2 and 5. The documentation and changelog half (items 3 and 4) is in #17400.

Item 1 — internal/pkg/agent/cmd/install.go, the install command's long help:

Before After
Unless all the require command-line parameters are provided or -f is used ... Unless all the required command-line parameters are provided or -f is used ...

Item 2 — internal/pkg/agent/cmd/enroll_cmd.go, the error wrapped when enrollment options fail to serialise:

-   "failed to marshall enrollment options",
+   "failed to marshal enrollment options",

Item 5 — the exlude comment in the EDOT kube-stack Helm values. The issue lists two occurrences; there is a third in the same chart that it missed, so I fixed all three to keep the chart consistent:

File Line Comment
deploy/helm/edot-collector/kube-stack/values.yaml 380 # exlude collector logs → # exclude collector logs
deploy/helm/edot-collector/kube-stack/managed_otlp/values.yaml 379 # exlude collector logs → # exclude collector logs
deploy/helm/edot-collector/kube-stack/managed_otlp/logs-values.yaml 200 # exlude opentelemetry-kube-stack pod logs → # exclude opentelemetry-kube-stack pod logs

(The issue cites lines 353 and 352 for the first two; they have since moved to 380 and 379.)

Deliberately out of scope: one more exlude remains in the repository, as the policy field name "exlude_files" in testing/integration/ess/escaping_secrets_in_policy_test.go:91. That is test input constructing a policy document rather than user-facing text, and renaming a key inside an integration test's fixture risks changing what the test actually exercises, so I left it alone. Worth a separate look by someone who knows whether that key is meant to mirror exclude_files.

Why is it important?

install.go's long help is what elastic-agent install --help prints, and it is the first thing a reader sees when deciding whether they can run the command non-interactively. The exlude comments are in the values files operators copy and edit when configuring log collection for the EDOT collector.

Checklist

  • My code follows the style guidelines of this project
  • I have made corresponding changes to the documentation
  • I have made corresponding change to the default configuration files
  • I have added tests that prove my fix is effective or that my feature works
  • I have added an entry in ./changelog/fragments using the changelog tool
  • I have added an integration test or an E2E test

No changelog fragment: all three changes are help text, an error message wording, and YAML comments, with no behaviour change, so this should carry skip-changelog. (The one item in this issue family that did warrant a fragment is in #17402, which fixes an error message that named the wrong mode.)

No test is added: the two Go changes are a cobra Long string and an error-wrapping message, and nothing asserts on either — searching *_test.go for marshall enrollment and the require command-line returns no matches.

Disruptive User Impact

None functionally. The failed to marshall enrollment options string changes, so anything grepping logs for that exact spelling would need updating; it is a wrapped error on an internal serialisation failure, so matching on it is unlikely.

How to test this PR locally

elastic-agent install --help   # "Unless all the required command-line parameters"

gofmt -l reports no changes needed on either Go file. A repository-wide search for exlude collector logs, exlude opentelemetry-kube-stack, marshall enrollment and the require command-line now returns no matches, and the only remaining exlude is the test fixture key noted above. The three YAML files keep their existing CRLF line endings.

I was not able to compile the packages locally: this checkout's beats submodule is not initialised, so the ./beats replace directive makes go build ./internal/... fail before reaching these files. Both edits are string-literal only, so I have left compilation and the unit suite to CI rather than claiming a local build.

Related issues

🤖 Generated with Claude Code


This is an automatic backport of pull request #17403 done by [Mergify](https://mergify.com).

)

Correct "all the require command-line parameters" in the install
command's long help, "marshall" in the enrollment error message, and
three "exlude" comments in the EDOT kube-stack values files.

Relates to #14578

Co-authored-by: Anshuman-Prakash <199287261+Anshuman-Prakash@users.noreply.github.com>
Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
Co-authored-by: Mikołaj Świątek <mail@mikolajswiatek.com>
(cherry picked from commit 75e2c2f)
@mergify
mergify Bot requested a review from a team as a code owner October 23, 2026 17:16
@mergify mergify Bot added the backport label Oct 23, 2026
@mergify
mergify Bot requested review from lorienhu and removed request for a team October 23, 2026 17:16
@github-actions github-actions Bot added documentation Improvements or additions to documentation Team:Elastic-Agent-Control-Plane Label for the Agent Control Plane team skip-changelog labels Oct 23, 2026
@infra-vault-gh-plugin-prod

Copy link
Copy Markdown

Pinging @elastic/elastic-agent-control-plane (Team:Elastic-Agent-Control-Plane)

@swiatekm
swiatekm enabled auto-merge (squash) October 23, 2026 17:20
@github-actions

Copy link
Copy Markdown
Contributor

Dependency review finished without posting an analysis comment.

If you expected a review, push a new commit to this pull request (or close and reopen it) to try again.

Workflow run: https://github.com/elastic/elastic-agent/actions/runs/39993672988

@mergify

mergify Bot commented Oct 23, 2026 •

Copy link
Copy Markdown
Contributor Author

This pull request does not currently match the merge queue conditions, so it cannot be queued from here. The box comes back if it matches again.

auto-merge was automatically disabled October 23, 2026 18:39

Branch protection rule check failed

@swiatekm
swiatekm merged commit e338202 into 9.4 Oct 28, 2026
44 checks passed
@swiatekm
swiatekm deleted the mergify/bp/9.4/pr-17403 branch October 28, 2026 14:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport documentation Improvements or additions to documentation skip-changelog Team:Elastic-Agent-Control-Plane Label for the Agent Control Plane team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants