Command reference
ed machines docker
ed machines docker is the parsed view of docker on another machine. Every verb
here opens the shared SSH connection, runs one real docker command with
--format '{{json .}}' where docker offers it, and turns the answer into stable
fields, so a script never has to scrape a column layout. It is the same set of
operations the app's Docker window performs. Pause and unpause share one
execution path across both interfaces, including target validation and timeout.
Nothing is installed on the far side and nothing is proxied through the Edith
app: this is /usr/bin/ssh over the connection the app shares. What they need is docker on the machine
and a user who can reach its socket.
The same commands work on Windows when Docker Desktop or Docker Engine is
running and docker is available to the SSH account. Edith wraps Windows host
commands in encoded PowerShell, while commands executed inside Linux containers
still use the container's sh. No change to the Windows OpenSSH default shell
is required.
There are two ways into docker on a machine, and the difference matters.
ed machines <machine> docker ps is this page: parsed, --json, stable keys.
ed <machine> docker ps is the raw shorthand, which sends the line to the
remote shell verbatim and gives you docker's own output and exit code. Reach for
the raw form for anything this page does not cover, ed devbox docker buildx ls
being the usual example.
At a glance
| Command | What it does |
|---|---|
ed machines docker shell |
Opens the same interactive container shell as the Docker window. |
ed machines docker ps |
Lists containers merged with live CPU and memory. Runs when you name no subcommand. |
ed machines docker images |
Lists images with their size and whether they are dangling. |
ed machines docker volumes |
Lists volumes with their driver and mountpoint. |
ed machines docker networks |
Lists networks with their driver and scope. |
ed machines docker df |
Disk usage by object type, with what is reclaimable. |
ed machines docker logs |
Streams one container's logs, with timestamps. |
ed machines docker inspect |
Reads structured image, command, environment, mount and network details. |
ed machines docker top |
Reads the processes running inside a container. |
ed machines docker open |
Opens one browser-reachable published TCP port. |
ed machines docker start |
Starts one or more containers. |
ed machines docker stop |
Stops one or more containers, with a 10 second grace period. |
ed machines docker restart |
Restarts one or more containers, with a 10 second grace period. |
ed machines docker rm |
Removes one or more containers, killing them first. Destructive, needs --yes. |
ed machines docker pause |
Freezes the processes of one or more containers. |
ed machines docker unpause |
Lets one or more frozen containers run again. |
ed machines docker rmi |
Removes an image. Destructive, needs --yes. Aliased remove-image. |
ed machines docker volume-rm |
Removes a volume and the data in it. Destructive, needs --yes. |
ed machines docker prune |
Reclaims space from unused objects. Destructive, needs --yes. |
ed machines docker compose config |
Prints and saves a masked effective configuration revision. Starts nothing. |
ed machines docker compose compare |
Compares images, bind mounts, ports and port conflicts in two saved revisions. |
ed machines docker compose ls |
Lists compose projects. Runs when you name no compose subcommand. Aliased list. |
ed machines docker compose up |
Brings a project up in the background. |
ed machines docker compose down |
Takes a project down, removing its containers and networks. Destructive. |
ed machines docker compose restart |
Restarts a project. |
ed machines docker compose pull |
Pulls the images a project uses. |
ed machines docker compose logs |
Streams the whole project's logs. |
What destroys data, and what guards it
Five verbs remove something. The direct container, image and volume removals,
plus prune, preview exact targets unless --yes is present.
The Docker window uses the same lifecycle operations and shows a confirmation
before it removes a container, image or volume, or prunes unused objects.
| Command | What disappears | Guard |
|---|---|---|
ed machines docker rm |
The container, killed first with docker rm -f. Anything written inside it and not in a volume goes with it. |
--yes |
ed machines docker rmi |
The image. With --force, even while a container still refers to it. |
--yes |
ed machines docker volume-rm |
The volume and every byte in it. This is where databases live. | --yes |
ed machines docker prune volumes |
Every volume no container currently uses, and their contents. | --yes |
ed machines docker prune images |
Every image no container uses, not only the dangling ones: the command is docker image prune -af. |
--yes |
ed machines docker compose down |
The project's containers and its network. Named volumes survive, because -v is never passed. |
none |
prune system, prune networks and prune builder remove stopped containers,
unused networks, dangling images and build cache. docker system prune -f is
what runs for system, without --volumes, so volume data is never caught by
it. Guarded commands without --yes report what they would do, change nothing,
and exit 0.
Commands
ed machines docker shelled machines docker psed machines docker imagesed machines docker volumesed machines docker networksed machines docker dfed machines docker logsed machines docker inspected machines docker toped machines docker started machines docker stoped machines docker restarted machines docker rmed machines docker pauseed machines docker unpauseed machines docker rmied machines docker volume-rmed machines docker pruneed machines docker compose lsed machines docker compose uped machines docker compose downed machines docker compose restarted machines docker compose pulled machines docker compose logs
Exit codes
| Code | When |
|---|---|
| 0 | The command did what it said. A guarded preview without --yes also exits 0, having changed nothing, and so do --help and --version. |
| 1 | Docker ran and refused, failed, or returned invalid structured output: no such container, an image still in use, a volume still attached, a compose file compose could not find, or an empty inspect/top result. The message names the verb and the machine, and docker's own stderr is the hint. Also a remote command that outran its timeout, and a logs stream whose ssh would not start. |
| 2 | --tail was negative, or the command line was wrong in the ordinary way: an unknown flag, a missing <machine> or <container>, a --tail that is not a number. |
| 3 | The machine name matched nothing or matched several; <what> was not one of the five prune targets; <project> was not in compose ls. |
| 4 | The machine could not be reached, docker on it is not usable (not installed, the daemon down, or this user cannot talk to the socket), ssh itself could not be launched for a non-streaming command, or open selected a binding the browser cannot reach. |
| other | shell, logs and compose logs propagate the remote process's own exit code verbatim, so anything docker or SSH returns reaches you unchanged. |
The docker availability failures all read the same way, with the specific reason as the hint:
error: docker is not usable on Devboxhint: docker is not installed thereThe other hints on that message are this user cannot talk to the docker socket, The Docker daemon is not running. and, when docker answered with
something unrecognisable, docker reported an unknown state.
Notes and gotchas
- Word order is free.
ed machines devbox docker psanded machines docker ps devboxare the same invocation: the machine is rewritten into the position the parser expects. A subcommand name always wins, so a machine literally calleddockerhas to be named ased machines show docker. ed devbox docker psis not this page. Naming a machine as the first word makes the rest a raw remote command, so that line runs docker's ownpson the machine and prints docker's own table. Addmachinesto get the parsed form. This is the escape hatch for everything not covered here:ed devbox docker buildx ls,ed devbox docker exec -it api sh.ed machines docker <machine>with no verb isps, anded machines docker compose <machine>with no verb iscompose ls.ed machines docker open <machine> <container>opens its only browser-reachable published TCP port. Pass--port <host-or-container-port>when it has more than one. A loopback-only binding on a remote machine exits 4 because it points at that machine, not this Mac. Publish it on a reachable address or add an SSH port forward.--jsonperforms the open and reports the resolved machine URL.ed machines docker shell <machine> <container>is the Docker window's shell button. Both use the same quoted container target and choosebashwhen it is available inside the container, falling back tosh.- Every verb, including both dry runs, starts by running
docker version --format '{{json .}}'on the machine with a 25 second ceiling and refusing to go on unless the daemon answered. That is the one round trip you pay for before anything else happens, and it is why an unreachable machine exits 4 even for a command that would have changed nothing. - Docker commands always run in the SSH login directory. The remembered
cdthated <machine> cd ...sets belongs toed machines execand does not reach this page, which is why the compose verbs pass a project name rather than a directory. - The timeouts are per command: 25 seconds for the version probe, 45 for
ps,images,volumesanddf, 30 fornetworks,inspect,topandcompose ls, 120 for every container lifecycle verb and forrmiandvolume-rm, 300 forpruneand forcompose up,downandrestart, 900 forcompose pull.shell,logsandcompose logshave none. A command that outruns its ceiling has itssshsentSIGTERM, thenSIGKILLtwo seconds later, and surfaces as exit 1 while the work carries on unsupervised on the machine. --jsonoutput is one document per invocation, keys sorted, two space indent. Nothing on this page streams JSON, and nothing here takes--json --follow.- Three verbs have no
--jsonat all:shell,logsandcompose logs. - Direct Docker verbs pass the container selector to docker as typed, so docker's
own name and id matching rules apply.
docker openresolves an exact name, short id or full id from the parsed container list before selecting a port. ps --jsondrops two fields it collects. Network rx and tx bytes are parsed out ofdocker statsand never reach the document; only CPU and memory do.- Volume sizes are never reported by
volumes. Usedf. - The Docker window and parsed CLI share shell, start, stop, restart, container removal, image removal, volume removal and prune operations. The four compose lifecycle verbs remain CLI-only because the window groups containers by compose project but never runs compose for a whole project.
- Some hints embed the machine's display name unquoted, so a machine whose name
has spaces produces a hint you cannot paste as is. Use the ssh alias,
devbox, or any unambiguous prefix instead. - These commands never need Edith to be running, and never ask macOS for a permission. Everything they touch is on the other machine.
Where to go next
ed machinesfor the machine directory itself, connecting and disconnecting, anded machines metricsfor the host the containers run on.- Running commands on a machine for the raw form,
--tty, and everything docker can do that this page does not parse. ed machines filesfor the compose files and bind mounts behind these projects.ed machines powerfor the systemd unit that starts docker, and for the machine's own power state.- Conventions and contracts for the exit code table and the
--jsonguarantees these commands follow. - The
edcommand line for the rest of the reference.