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

hotfix(agent): only retain 1 logfile at a time #7815

Merged
merged 2 commits into from
Jun 2, 2023
Merged

Conversation

coadler
Copy link
Member

@coadler coadler commented Jun 2, 2023

No description provided.

Copy link

@cdr-bot cdr-bot bot left a comment

Choose a reason for hiding this comment

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

This PR is a hotfix and has been automatically approved.

  • ✅ Base is main
  • ✅ Head is from coder/coder
  • ✅ Less than 100 lines
  • ✅ Title matches ^hotfix(\(.+\))?:.*$

@coadler coadler self-assigned this Jun 2, 2023
MaxSize: 5, // MB
Filename: filepath.Join(logDir, "coder-agent-init.log"),
MaxSize: 5, // MB
MaxBackups: 1,
Copy link
Member

Choose a reason for hiding this comment

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

I'm guessing this is to avoid gigabytes of logs in /tmp? Perhaps a comment for posterity and to avoid regressions?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yeah, it correctly rotates logs at 5mb but it leaves the old logs around forever without this.

@coadler coadler merged commit 6fdebd8 into main Jun 2, 2023
18 checks passed
@coadler coadler deleted the colin/log-max-backups branch June 2, 2023 17:28
@github-actions github-actions bot locked and limited conversation to collaborators Jun 2, 2023
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.

None yet

2 participants