Skip to content

[Feature]: Tail attached logs #3035

@antoniojtorres

Description

@antoniojtorres

Problem

When a task or other dstack process has been running for a while and has generated substantial logs, it becomes difficult to spot check recent logs. When running dstack attach my-task --logs, dstack streams logs in ascending order from the very beginning, which can be impractical in many scenarios and a non-starter in others.

Solution

In the same vein as docker logs, it would be useful to pass the --tail flag to stream N lines from the end of the logs instead of the beginning. Optionally, passing a line count ( --tail 50) can help the user dial in what they need.

Workaround

No response

Would you like to help us implement this feature by sending a PR?

No

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions