Skip to content

[Fleet] Do not generate agent.protection and signed part full policy for standalone policies#217897

Merged
nchaulet merged 3 commits into
elastic:mainfrom
nchaulet:feature-no-signed-protection-full-standalone
Apr 14, 2025
Merged

[Fleet] Do not generate agent.protection and signed part full policy for standalone policies#217897
nchaulet merged 3 commits into
elastic:mainfrom
nchaulet:feature-no-signed-protection-full-standalone

Conversation

@nchaulet
Copy link
Copy Markdown
Member

Description

Resolve #217895

We should not generate agent.protection and signed part of the full policy for standalone policies, that PR fix that.

Tests

I added relevant unit tests.

Try to add a standalone agent and check the related properties are not present

Screenshot 2025-04-10 at 2 02 03 PM

@nchaulet nchaulet added release_note:skip Skip the PR/issue when compiling release notes backport:skip This PR does not require backporting Team:Fleet Team label for Observability Data Collection Fleet team labels Apr 10, 2025
@nchaulet nchaulet self-assigned this Apr 10, 2025
@nchaulet nchaulet requested a review from a team as a code owner April 10, 2025 18:02
@elasticmachine
Copy link
Copy Markdown
Contributor

Pinging @elastic/fleet (Team:Fleet)

@nchaulet
Copy link
Copy Markdown
Member Author

@elasticmachine merge upstream

}
if (options?.standalone) {
delete fullAgentPolicy.agent?.protection;
delete fullAgentPolicy.signed;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

nit: do we need this line if signed is not set in the previous conditional?

Copy link
Copy Markdown
Contributor

@juliaElastic juliaElastic left a comment

Choose a reason for hiding this comment

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

LGTM

@nchaulet
Copy link
Copy Markdown
Member Author

@elasticmachine merge upstream

@elasticmachine
Copy link
Copy Markdown
Contributor

💚 Build Succeeded

Metrics [docs]

✅ unchanged

History

cc @nchaulet

@nchaulet nchaulet merged commit 530dd5b into elastic:main Apr 14, 2025
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:skip This PR does not require backporting release_note:skip Skip the PR/issue when compiling release notes Team:Fleet Team label for Observability Data Collection Fleet team v9.1.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Fleet] When creating a standalone agent policy, exclude the signed and protection policy sections

4 participants