Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

feat(codersdk): add debug handlers for logs, manifest, and token to agent#12593

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
johnstcn merged 3 commits intomainfromcj/agent-add-debug-handlers
Mar 14, 2024

Conversation

johnstcn
Copy link
Member

@johnstcnjohnstcn commentedMar 14, 2024
edited
Loading

Part of#12161

Adds the following debug handlers to the agent API:

  • /debug/manifest: returns the in-memory agent manifest
  • /debug/token: returns the in-memory agent session token
  • /debug/logs: returns up to the last 10MB of the agent log.

We can technically get these by connecting to the agent over SSH but this seems to be a better way overall.

@johnstcnjohnstcn self-assigned thisMar 14, 2024
@johnstcnjohnstcn marked this pull request as ready for reviewMarch 14, 2024 15:01
Copy link
Member

@mtojekmtojek left a comment

Choose a reason for hiding this comment

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

LGTM

}
defer f.Close()

// Limit to 10MB.
Copy link
Member

Choose a reason for hiding this comment

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

Should we limit this in the head or tail-end? A workspace running for a long time could have more relevant information towards the end. Then again, we seem to rotate at 5 MB so this will essentially always give the tail.

Copy link
MemberAuthor

Choose a reason for hiding this comment

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

Yep, this was my thinking. I was thinking about tailing but the fact that we rotate makes this not as important.

@johnstcnjohnstcn merged commit63696d7 intomainMar 14, 2024
@johnstcnjohnstcn deleted the cj/agent-add-debug-handlers branchMarch 14, 2024 15:36
@github-actionsgithub-actionsbot locked and limited conversation to collaboratorsMar 14, 2024
Sign up for freeto subscribe to this conversation on GitHub. Already have an account?Sign in.
Reviewers

@mafredrimafredrimafredri approved these changes

@mtojekmtojekmtojek approved these changes

@deansheatherdeansheatherAwaiting requested review from deansheather

Assignees

@johnstcnjohnstcn

Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

3 participants
@johnstcn@mafredri@mtojek

[8]ページ先頭

©2009-2025 Movatter.jp