Brev CLI
Use this skill for generic Brev instance lifecycle operations that support
Content Agents deployment skills.
When to Use
- A deployment skill asks you to list, create, access, port-forward, stop, or
delete Brev instances.
- The user asks for direct Brev CLI help outside a service-specific deployment
skill.
- A collection deployment needs a generic Brev lifecycle step before handing
off to
$fixed-pipeline and its deploy-ovrtx-docker,
deploy-qwen-vlm-brev, deploy-image-gen-brev, or
deploy-embeddings-brev reference.
Limitations
- Do not create paid instances or delete existing instances without explicit
user approval for the exact target.
- Do not print, log, or copy secrets unless the user has provided a safe secret
handling path.
- Do not assume instance-to-instance private networking is available. Prefer
explicit port-forwards or user-provided endpoint URLs.
- Do not invent GPU type names. Use
brev ls --json, brev search --json, or
a service-specific skill's validated instance type.
Prerequisites
- Brev CLI installed and authenticated.
- Network access from the local machine to the Brev control plane.
- SSH readiness for commands that use
brev exec, brev copy, or direct
ssh.
- The
$fixed-pipeline umbrella and selected deployment reference loaded when
configuring OVRTX, model, image-generation, or embedding containers.
Instructions
- Check local CLI state, current resources, and available hardware. Skip
brev search --json only when the selected fixed-pipeline reference already gives an
exact validated instance type:
brev --version
brev healthcheck
brev ls --json
brev search --json
- Reuse an existing instance only when its name or purpose matches the
requested role, it is not deleting, its status and shell access are usable,
its GPU/type/disk satisfy the service-specific requirement, and no other
owner or run is actively using it. If no instance matches, run a dry-run
first;
<gb> is the Brev CLI disk-size value in GB:
brev create <name> --dry-run --type <instance-type> --min-disk <gb>
- After the user approves the exact instance name and type, create it:
brev create <name> --type <instance-type> --min-disk <gb> --timeout 1200
- Wait until the instance is shell-ready before copying files or starting
containers:
brev exec <name> "uname -a && nvidia-smi || true"
- Copy only the files needed by the service-specific workflow. Keep local
.env files and secrets out of bulk copies unless the user explicitly asks
for a credential-copy step:
brev copy <local-path> <name>:<remote-path>
- Run remote commands through
brev exec or a named SSH host. Prefer
the selected fixed-pipeline deployment reference for container startup commands:
brev exec <name> "cd <remote-path> && <command>"
- Forward endpoints explicitly and keep the forwarding process running while
local agents use it. Prefer a foreground terminal or tool session. If the
process must run in the background, save its PID or terminal/session name so
cleanup can stop the exact port-forward:
brev port-forward <name> -p <local-port>:<remote-port>
- Clean up port-forward processes, then choose exactly one instance cleanup
action when validation is complete. Use
brev stop when delete is delayed,
delete is not supported, or the user asks to preserve the workspace without
spend:
brev stop <name>
Use brev delete only when the user wants the instance removed:
brev delete <name>
After either cleanup action, confirm state:
brev ls --json
Command Reference
| Goal |
Command |
| Check auth and CLI health |
brev healthcheck |
| List instances |
brev ls --json |
| Find available hardware |
brev search --json |
| Preview spend |
brev create <name> --dry-run --type <type> --min-disk <gb> |
| Create instance |
brev create <name> --type <type> --min-disk <gb> --timeout 1200 |
| Run remote command |
brev exec <name> "<command>" |
| Copy files |
brev copy <local-path> <name>:<remote-path> |
| Forward port |
brev port-forward <name> -p <local-port>:<remote-port> |
| Stop spend when supported |
brev stop <name> |
| Delete instance |
brev delete <name> |
Output Format
Report the instance name, instance type, current status, commands run, endpoint
or port-forward URL, any port-forward PID/session to stop, and the brev stop
or brev delete cleanup command. Mention any command that requires user
approval before running it.
Troubleshooting
- If
brev healthcheck fails, ask the user to refresh Brev authentication and
rerun the command.
- If shell readiness fails after creation, poll
brev ls --json and retry a
lightweight brev exec before starting containers.
- If
brev port-forward only binds localhost but Docker containers need the
endpoint, use a carefully scoped SSH forward bound to the host interface and
restrict access with host firewall rules.
- If delete is delayed, stop the instance when supported and poll
brev ls --json until the instance disappears.
1---2name: brev-cli3description: Manage Brev instances safely from the Brev CLI. Use when a workflow needs to list, create, access, copy to, execute on, port-forward, stop, or delete Brev instances for Content Agents dependency endpoints.4---56# Brev CLI78Use this skill for generic Brev instance lifecycle operations that support9Content Agents deployment skills.1011## When to Use1213- A deployment skill asks you to list, create, access, port-forward, stop, or14 delete Brev instances.15- The user asks for direct Brev CLI help outside a service-specific deployment16 skill.17- A collection deployment needs a generic Brev lifecycle step before handing18 off to `$fixed-pipeline` and its `deploy-ovrtx-docker`,19 `deploy-qwen-vlm-brev`, `deploy-image-gen-brev`, or20 `deploy-embeddings-brev` reference.2122## Limitations2324- Do not create paid instances or delete existing instances without explicit25 user approval for the exact target.26- Do not print, log, or copy secrets unless the user has provided a safe secret27 handling path.28- Do not assume instance-to-instance private networking is available. Prefer29 explicit port-forwards or user-provided endpoint URLs.30- Do not invent GPU type names. Use `brev ls --json`, `brev search --json`, or31 a service-specific skill's validated instance type.3233## Prerequisites3435- Brev CLI installed and authenticated.36- Network access from the local machine to the Brev control plane.37- SSH readiness for commands that use `brev exec`, `brev copy`, or direct38 `ssh`.39- The `$fixed-pipeline` umbrella and selected deployment reference loaded when40 configuring OVRTX, model, image-generation, or embedding containers.4142## Instructions43441. Check local CLI state, current resources, and available hardware. Skip45 `brev search --json` only when the selected fixed-pipeline reference already gives an46 exact validated instance type:4748```bash49brev --version50brev healthcheck51brev ls --json52brev search --json53```54552. Reuse an existing instance only when its name or purpose matches the56 requested role, it is not deleting, its status and shell access are usable,57 its GPU/type/disk satisfy the service-specific requirement, and no other58 owner or run is actively using it. If no instance matches, run a dry-run59 first; `<gb>` is the Brev CLI disk-size value in GB:6061```bash62brev create <name> --dry-run --type <instance-type> --min-disk <gb>63```64653. After the user approves the exact instance name and type, create it:6667```bash68brev create <name> --type <instance-type> --min-disk <gb> --timeout 120069```70714. Wait until the instance is shell-ready before copying files or starting72 containers:7374```bash75brev exec <name> "uname -a && nvidia-smi || true"76```77785. Copy only the files needed by the service-specific workflow. Keep local79 `.env` files and secrets out of bulk copies unless the user explicitly asks80 for a credential-copy step:8182```bash83brev copy <local-path> <name>:<remote-path>84```85866. Run remote commands through `brev exec` or a named SSH host. Prefer87 the selected fixed-pipeline deployment reference for container startup commands:8889```bash90brev exec <name> "cd <remote-path> && <command>"91```92937. Forward endpoints explicitly and keep the forwarding process running while94 local agents use it. Prefer a foreground terminal or tool session. If the95 process must run in the background, save its PID or terminal/session name so96 cleanup can stop the exact port-forward:9798```bash99brev port-forward <name> -p <local-port>:<remote-port>100```1011028. Clean up port-forward processes, then choose exactly one instance cleanup103 action when validation is complete. Use `brev stop` when delete is delayed,104 delete is not supported, or the user asks to preserve the workspace without105 spend:106107```bash108brev stop <name>109```110111Use `brev delete` only when the user wants the instance removed:112113```bash114brev delete <name>115```116117After either cleanup action, confirm state:118119```bash120brev ls --json121```122123## Command Reference124125| Goal | Command |126|---|---|127| Check auth and CLI health | `brev healthcheck` |128| List instances | `brev ls --json` |129| Find available hardware | `brev search --json` |130| Preview spend | `brev create <name> --dry-run --type <type> --min-disk <gb>` |131| Create instance | `brev create <name> --type <type> --min-disk <gb> --timeout 1200` |132| Run remote command | `brev exec <name> "<command>"` |133| Copy files | `brev copy <local-path> <name>:<remote-path>` |134| Forward port | `brev port-forward <name> -p <local-port>:<remote-port>` |135| Stop spend when supported | `brev stop <name>` |136| Delete instance | `brev delete <name>` |137138## Output Format139140Report the instance name, instance type, current status, commands run, endpoint141or port-forward URL, any port-forward PID/session to stop, and the `brev stop`142or `brev delete` cleanup command. Mention any command that requires user143approval before running it.144145## Troubleshooting146147- If `brev healthcheck` fails, ask the user to refresh Brev authentication and148 rerun the command.149- If shell readiness fails after creation, poll `brev ls --json` and retry a150 lightweight `brev exec` before starting containers.151- If `brev port-forward` only binds localhost but Docker containers need the152 endpoint, use a carefully scoped SSH forward bound to the host interface and153 restrict access with host firewall rules.154- If delete is delayed, stop the instance when supported and poll155 `brev ls --json` until the instance disappears.