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

Backport of logs: allow disabling log collection in jobspec into release/1.5.x #16970

Conversation

hc-github-team-nomad-core
Copy link
Contributor

Backport

This PR is auto-generated from #16962 to be assessed for backporting due to the inclusion of the label backport/1.5.x.

The below text is copied from the body of the original PR.


Some Nomad users ship application logs out-of-band via syslog or the like. For these users having logmon (and docker_logger) running is unnecessary overhead. Allow disabling the logmon and pointing the task's stdout/stderr to /dev/null.

This changeset is the first of several incremental improvements to log collection short of full-on logging plugins. The next step will likely be to extend the internal-only task driver configuration so that cluster administrators can turn off log collection for the entire driver (as described in #15686 and #14636)


Fixes: #11175

Notes to reviewers:

  • In addition to the unit tests here, I've verified this works as expected with docker and raw_exec tasks, with and without the logs.enabled set, including requiring destructive updates to the alloc if we change the value.
  • Although we have an existing disable_logging_collection field for the driver, I went with enabled here to be more consistent with other jobspec fields and our inclusive language guidelines. I suspect most folks won't touch it, in any case.
  • Once this is merged I'll open a follow-up issue for disabling the logs UI if LogConfig.Enabled = false. But I've verified it doesn't cause any weird crashing behavior, the panel is just empty.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants