-
Notifications
You must be signed in to change notification settings - Fork 144
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
Allow setting ES api key via env variable in container mode #5536
Conversation
This pull request does not have a backport label. Could you fix it @swiatekm? 🙏
|
|
70c4371
to
5753c1d
Compare
@ycombinator @nimarezainia if this is considered a breaking shouldn't make it land only in 9.x? |
5753c1d
to
5aebbd0
Compare
Also remove defaults for username and password set this way.
5aebbd0
to
d7efc01
Compare
Pinging @elastic/elastic-agent-control-plane (Team:Elastic-Agent-Control-Plane) |
Quality Gate passedIssues Measures |
This is to bring the docs in line with the change in elastic/elastic-agent#5536.
This is to bring the docs in line with the change in elastic/elastic-agent#5536.
@swiatekm Are we good to merge this in 9.0? |
I think so. I considered adding an E2E test for it, but it ended up being a lot of setup for such a trivial check. |
Yes, this is a breaking change and is OK to merge (only) in |
This is to bring the docs in line with the change in elastic/elastic-agent#5536.
What does this PR do?
Remove defaults for username and password when running in container mode, and also allow api_key to be set in that mode via the
ELASTICSEARCH_API_KEY
environment variable.Note that the first of these changes is breaking. I've added two separate changelog entries to make this clear.
Why is it important?
It's very useful for users to be able to use an ES api key for authentication without needing to override the whole config file.
Checklist
./changelog/fragments
using the changelog toolDisruptive User Impact
This is a breaking change for users who rely on the default username and password in container mode. These users will need to explicitly set these values after this change is rolled out. After the upgrade, the agent will simply fail to start, and will complain about lack of authentication credentials.
How to test this PR locally
This should successfully start if the host and api key are valid.
Related issues
Closes #97.