-
Notifications
You must be signed in to change notification settings - Fork 4.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix: select default agent policy if no enrollment token provided #23973
Conversation
Pinging @elastic/ingest-management (Team:Ingest Management) |
Pinging @elastic/agent (Team:Agent) |
💚 Build Succeeded
Expand to view the summary
Build stats
Test stats 🧪
Trends 🧪💚 Flaky test reportTests succeeded. Expand to view the summary
Test stats 🧪
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
jenkins run the tests please |
/test |
2 similar comments
/test |
/test |
Errors seem to be unrelated. |
…stic#23973) * Fix: select default agent policy if no enrollment token provided * Update CHANGELOG (cherry picked from commit e3da3be)
What does this PR do?
This PR fixes the non-determinism in agent's policy selection. With this bugfix, the agent will always enroll using the default policy unless the custom enrollment token is selected.
Why is it important?
Currently the enrollment script (Docker) selects the newest policy. It may happen that the selected policy is not active or it is not intended to be used.
Checklist
- [ ] I have commented my code, particularly in hard-to-understand areas- [ ] 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 worksCHANGELOG.next.asciidoc
orCHANGELOG-developer.next.asciidoc
.Author's Checklist
How to test this PR locally
Expected:
3. Elastic Agent should be started with Default policy, not the newest one (just added).
Related issues
Use cases
Screenshots
Logs