bdy sandbox create

$bdy sandbox create|add [options]

Create a new sandbox. Pre-installed tools: node 24, docker 29, go 1.25, python 3, git, curl, wget, jq, rsync, ripgrep, unzip, nano, bdy

OPTIONS
-w, --workspace <domain>
Workspace URL handle. Can be set via variable: BUDDY_WORKSPACE
-p, --project <name>
Project name. Can be set via variable: BUDDY_PROJECT
-n, --name <name>
Sandbox display name
-i, --identifier <identifier>
Sandbox identifier
--os <image>
Operating system image (ubuntu:24.04 (default), ubuntu:22.04)
--snapshot <snapshot-name>
Create from snapshot name (instead of OS)
--resources <spec>
Resource allocation: 1x2, 2x4, 4x8, 8x16, 12x24 (CPUxRAM)
--boot-command <commands...>
Setup commands to run on creation (can be used multiple times)
--boot-script <filepath>
Path to a file with setup commands to run on creation (one per line). Plain commands only — no shebang, the file content is executed as-is
--app-command <commands...>
Application command to run at startup (can be used multiple times)
--app-dir <directory>
Application directory of the sandbox
--tag <tags...>
Tags to add on creation (can be used multiple times)
--timeout <seconds>
The timeout in seconds after which the sandbox will be automatically stopped
--fetch [fetch...]
Fetch sources (can be used multiple times).
-v, --variable <variables...>
Variable key=value or key:value. Can be passed multiple times to pass multiple variables
-vf, --variables-from-file <filepath>
File with variables, key=value. Each variable in new line
-vff, --variable-from-file <variables...>
Variable from file, key=path/to/file or key:path/to/file. Can be passed multiple times to pass multiple variables
-vm, --variable-masked <variables...>
Variable key=value or key:value. Can be passed multiple times to pass multiple variables
-vmf, --variables-masked-from-file <filepath>
File with variables, key=value. Each variable in new line
-vmff, --variable-masked-from-file <variables...>
Variable from file, key=path/to/file or key:path/to/file. Can be passed multiple times to pass multiple variables
--yaml <content|@path>
Complete sandbox YAML. To specify file use @path/to/file format in value
--wait-for-running [seconds]
Wait until sandbox is running
--wait-for-configured [seconds]
Wait until sandbox ran setup commands
--wait-for-apps [seconds]
Wait until sandbox apps are running
-h, --help
display help for command

Documentation for bdy v1.22.49

Last modified on May 19, 2026

Examples

## create ubuntu 22.04 sandbox with name and wait for start
bdy sb create -n "name" --os ubuntu:22.04 --wait-for-running$
## create sandbox with identifier, run install commands and wait for start & commands to complete
bdy sb create -i "test" --boot-command "apt-get update && apt-get install nginx -y" --wait-for-configured$
## run commands from the file
bdy sb create --boot-script /path/to/file$
## create sandbox with custom resources and tag it
bdy sb create --resources 4x8 --tag "tag1" --tag "tag2"$
## create sandbox and fetch project repository from default branch to working directory
bdy sb create --fetch$
## create sandbox and fetch project repository branch
bdy sb create --fetch feature-branch$
## create sandbox and fetch public repository
bdy sb create --fetch "path=/home/buddy/repo,url=https://public-repo.com,ref=feature-branch"$
## create sandbox and fetch artifact
bdy sb create --fetch "path=/home/buddy/repo,artifact=name@version"$
## create sandbox, fetch project repo branch and build
bdy sb create --fetch "path=/home/buddy/repo,ref=branch,build=npm install && npm run build"$
## create sandbox and pass custom variables
bdy sb create -v key:val -v a:b$
## create sandbox and pass custom variables from file
bdy sb create -vf path/to/env/file$
## create sandbox from yaml file
bdy sb create --yaml @./test.yml"$
## create http endpoint on port 80 (http server must listen on 0.0.0.0)
bdy sb ep create sandbox-identifier -e 80$
## create http server and serve files from sandbox directory
bdy sb ep create sandbox-identifier -s /path/to/dir$
## create tcp endpoint on port 22 with name (tcp server must listen on 0.0.0.0)
bdy sb ep create sandbox-identifier -t TCP -e 22 -n test$