bdy target exec

View as Markdown
$bdy target exec [options] [command]

Execute a command on a target

OPTIONS
-h, --help
display help for command
AVAILABLE COMMANDS
Execute a command on a target
Cancel a running execution
List target executions
Get execution logs
Get execution status

Documentation for bdy v1.24.8

Last modified on Sep 3, 2026

Examples

Run a command on a target and print its output
bdy tg exec command target-identifier "ls -la"$
Run SQL on a MySQL target
bdy tg exec command target-identifier "SELECT 1"$
Start a command in background and return the execution id
bdy tg exec command target-identifier "ls -la" --async$
Run a command from a file
bdy tg exec command target-identifier --file ./query.sql$
Print the result with execution metadata as JSON
bdy tg exec command target-identifier "SELECT 1" --format json$
Cancel running execution
bdy tg exec kill exec-id$
Cancel running execution and automatically confirm
bdy tg exec kill exec-id -f$
List executions of a target
bdy tg exec ls target-identifier$
List last 5 executions
bdy tg exec ls target-identifier --limit 5$
Show logs of execution
bdy tg exec logs exec-id$
Show logs of execution starting from line 100
bdy tg exec logs exec-id --offset 100$
Show status of execution
bdy tg exec status exec-id$