mirror of
https://github.com/docker/docs.git
synced 2026-11-04 10:01:00 +00:00
Vendor the checked-in CLI YAML from Docker Sandboxes release/v0.51 at 7d55286de0c7. This updates command help, adds `sbx policy check http`, and replaces seven agent-specific create pages with redirects to `sbx create`. Validation: full site build with Hugo 0.169.0; upstream byte-for-byte comparison; all 115 command pages, reference links, and seven redirects checked; template formatting and whitespace checks passed.
65 lines
2.5 KiB
YAML
65 lines
2.5 KiB
YAML
name: sbx rm
|
|
synopsis: Remove one or more sandboxes
|
|
description: |-
|
|
Remove one or more sandboxes. Or — with --cloud — the cloud sandbox
|
|
ID (sbx_*) or name from "sbx --cloud ls".
|
|
|
|
For local sandboxes, stops them, removes their containers, cleans up any Git
|
|
worktrees, deletes sandbox state, and deletes secrets scoped to each removed
|
|
sandbox. Host-mount directories and persistent volume@1 storage created with
|
|
retention support are kept; creating the same sandbox name with the same kit
|
|
reattaches its persistent volumes. This action cannot be undone. With --cloud, deletes
|
|
the sandbox in Docker Sandboxes Cloud. This action cannot be undone. Once the
|
|
server accepts the request, rm waits up to 60 seconds per sandbox for the
|
|
deletion. A removal still completing after that exits 0. Verify it later with
|
|
"sbx --cloud ls".
|
|
|
|
Removal requires confirmation; use --force to skip confirmation prompts
|
|
(for non-interactive scripts) and to delete a sandbox that is in use
|
|
(e.g. an open SSH connection). Use --all to remove every sandbox. With --cloud, --all is
|
|
intentionally disabled as a safety gate — the blast radius covers every
|
|
sandbox the credential can see, which may include shared or production
|
|
workloads. Pass IDs explicitly in --cloud mode.
|
|
usage: sbx rm [SANDBOX...] [flags]
|
|
options:
|
|
- name: all
|
|
default_value: "false"
|
|
usage: Remove all sandboxes
|
|
- name: force
|
|
shorthand: f
|
|
default_value: "false"
|
|
usage: |
|
|
Skip confirmation prompts and delete even if in use (e.g. an open SSH connection)
|
|
- name: format
|
|
usage: 'Output format: table, json or yaml'
|
|
- name: help
|
|
shorthand: h
|
|
default_value: "false"
|
|
usage: help for rm
|
|
- name: json
|
|
default_value: "false"
|
|
usage: Output in JSON format
|
|
inherited_options:
|
|
- name: cloud
|
|
default_value: "false"
|
|
usage: |
|
|
Dispatch to Docker Cloud Sandboxes API instead of local sandboxd (supported by a growing set of verbs — run 'sbx --cloud --help' for the current list)
|
|
- name: debug
|
|
shorthand: D
|
|
default_value: "false"
|
|
usage: Enable debug logging
|
|
- name: no-input
|
|
default_value: "false"
|
|
usage: |
|
|
Never prompt; commands that need an answer fail with the command to run instead
|
|
example: |4-
|
|
sbx rm my-sandbox
|
|
|
|
# Remove several at once
|
|
sbx rm one two
|
|
|
|
# Remove every sandbox without asking
|
|
sbx rm --all --force
|
|
see_also:
|
|
- sbx - Manage AI coding agent sandboxes.
|