Fix permissions on default state sub-directories when Agent runs as container#2330
Merged
ycombinator merged 4 commits intoelastic:mainfrom Mar 1, 2023
Merged
Conversation
Contributor
Contributor
🌐 Coverage report
|
michalpristas
approved these changes
Mar 1, 2023
Contributor
michalpristas
left a comment
There was a problem hiding this comment.
components should not write any logs since 8.6, agent collects them and they are part of single log file, but i'm ok with the change
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
This PR fixes the permissions of the
state/data/tmpandstate/data/logsfolders when they're setup as part ofelastic-agent containerrunning.Why is it important?
To allow processes within the same group as
elastic-agent, e.g. Heartbeat, to write to thestate/data/tmpandstate/data/logsfolders.Note that there is another folder that's a sibling of those two,
state/data/runbut it already has the correct permissions, so this PR doesn't do anything with it.Checklist
./changelog/fragmentsusing the changelog toolAuthor's Checklist
How to test this PR locally
/usr/share/elastic-agent/state/data. Verify that all of them are group-writeable.Related issues
Use cases
Screenshots
Before this PR
After this PR
Logs