-
Notifications
You must be signed in to change notification settings - Fork 171
Description
Summary
Currently, when executing a BOSH errand via the CLI (bosh run-errand ), operators do not receive any log output until the errand completely finishes (or fails). We are requesting a feature to stream the errand's stdout and stderr logs to the BOSH CLI in real-time as the errand executes.
Current Behavior
When an operator runs an errand, the CLI initiates the task and waits. For long-running errands (like database migrations, heavy smoke tests, or large data cleanups), the operator sits looking at a static screen for minutes or even hours.
There is no visibility into whether the errand is actively progressing, hung, or stuck in a retry loop.
The logs are only fetched and dumped to the console after the errand exits.
Desired Behavior
The bosh run-errand command should stream the logs (both stdout and stderr) from the errand VM directly to the user's terminal in real-time.
As the script running on the VM outputs a line, it should appear in the CLI task output.
If log streaming is too verbose for certain users, it could be hidden behind a flag (e.g., bosh run-errand --stream-logs), though defaulting to streaming (similar to standard CI/CD pipelines) would provide the best operator experience.
Use Cases & Motivation
Improved Operator Experience: Operators won't have to guess if a 20-minute database migration has stalled.
Faster Debugging: If an errand gets stuck in an infinite loop, an operator can see it immediately, cancel the task, and fix the issue, rather than waiting for a hard timeout.
Consistency: Other ecosystem tools (like Kubernetes pods or standard Docker containers) default to real-time log streaming. Bringing this to BOSH errands modernizes the deployment experience.
Acceptance Criteria
[ ] The BOSH Director captures real-time stdout/stderr from the errand execution via the agent.
[ ] The BOSH CLI displays these logs as they are generated during the run-errand task.
[ ] The final log archive is still successfully gathered and stored by the Director upon errand completion, preserving backward compatibility.
Metadata
Metadata
Assignees
Labels
Type
Projects
Status