Skip to main content
porter sandbox contains commands for managing sandboxes on a Porter cluster.

Prerequisites


porter sandbox logs

Fetches and prints recent log lines from a sandbox. Each line renders as <RFC3339-timestamp> [<level>] <text>, with level-colored brackets when stdout is a TTY (red for error, yellow for warning, default for info). Usage:
porter sandbox logs <sandbox-id> [flags]
Options:
FlagDescription
--since <duration>Lookback window as a Go duration (e.g. 30m, 1h30m). Defaults to 1h.
--limit <n>Maximum number of log lines to return. Server cap is 5000; 0 uses the server default. Defaults to 500.
--tail <n>Alias for --limit (kubectl style). When > 0, overrides --limit.
--level <level>Client-side severity filter: info, warning, or error. Empty (default) returns all levels.
--no-timestampsSuppress the leading RFC3339 timestamp on each line.
porter sandbox logs abc123
--tail wins when both --limit and --tail are set to different non-zero values. A warning is printed to stderr in that case.
Invalid values for --since, --level, --limit, or --tail exit with status code 2 (usage error), consistent with the other porter sandbox subcommands.