Skip to content
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

[agent] change the default journald directory #1110

Merged
merged 4 commits into from
Jan 10, 2024

Conversation

atoulme
Copy link
Contributor

@atoulme atoulme commented Jan 9, 2024

Description:
Change the default journald directory to match the default of the receiver:
https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/receiver/journaldreceiver

@atoulme atoulme requested review from a team as code owners January 9, 2024 22:48
@atoulme atoulme force-pushed the change_default_journald_directory branch from c8e7454 to c179f4c Compare January 10, 2024 00:03
# Please update directory path for journald if it's different from below default value "/var/log/journal"
directory: /var/log/journal
# Please update directory path for journald if it's different from below default value "/run/log/journal"
directory: /run/log/journal
Copy link
Contributor

Choose a reason for hiding this comment

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

Why would we need to specify a value to begin with?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

oh true, the default value can be an empty string.

Copy link
Contributor

Choose a reason for hiding this comment

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

https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/0d4683eb03d3f1aebb427fa094e0baff638deab6/pkg/stanza/operator/input/journald/journald.go#L101 empty string would still cause setting the --directory option so I think leaving the field commented would be preferable?

Copy link
Contributor

Choose a reason for hiding this comment

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

missed that this is required for volume, so deferring to node default isn't possible as is (which answers my question).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

understood, I'll revert and use the /run/log/journal then.

@atoulme atoulme force-pushed the change_default_journald_directory branch from d931f7d to b2aa040 Compare January 10, 2024 17:20
@atoulme atoulme merged commit b186042 into main Jan 10, 2024
32 checks passed
@atoulme atoulme deleted the change_default_journald_directory branch January 10, 2024 22:35
@github-actions github-actions bot locked and limited conversation to collaborators Jan 10, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants