feat(cli): add logs cmd (#21430)

This PR adds a command to view the provisioner and agent logs for a
given workspace.
Note: I did investigate using the existing `cliui` methods to tail the
logs but they are tailored to a very specific use-case.

Other changes:
- Adds `Agents` to `dbfake.WorkspaceResponse`
- Adds methods to generate provisioner and agent logs in `dbgen`

---------

Co-authored-by: Steven Masley <Emyrk@users.noreply.github.com>
This commit is contained in:
Cian Johnston
2026-01-08 09:58:10 +00:00
committed by GitHub
co-authored by Steven Masley
parent 49b34a716a
commit 0f446f99dd
10 changed files with 480 additions and 0 deletions
+1
View File
@@ -28,6 +28,7 @@ SUBCOMMANDS:
list List workspaces
login Authenticate with Coder deployment
logout Unauthenticate your local session
logs View logs for a workspace
netcheck Print network debug information for DERP and STUN
notifications Manage Coder notifications
open Open a workspace