Connect to another machine
Open an interactive terminal on another machine that has joined the fleet:
cmdop connect <machine>Run cmdop connect without a machine name to choose from the available online
machines. The picker deliberately hides this machine and offline machines — add
--all to include them:
cmdop connect # picker: other online machines
cmdop connect --all # picker: also offline machines and this machine
cmdop connect prod-srv # direct
cmdop connect pr # name prefix; picker opens if ambiguousAn explicit machine name resolves exactly and can target an offline machine
even without --all.
To inspect candidates without connecting:
cmdop connect --list
cmdop connect --list --online
cmdop connect --list --json--online narrows --list to machines that are currently up. For an inventory
across every fleet you belong to rather than just this one, use
cmdop machines.
In a script or a pipe, pass the machine name explicitly: --json and
-q/--no-interactive never prompt, and fail fast rather than hanging when
something is missing.
Run one command
connect exec is currently limited to a target resolved through this host’s
embedded relay. It is not a general cross-host automation command. For that
local-relay scope, place the command after --:
cmdop connect exec <machine> -- uptime
cmdop connect exec <machine> --timeout 60 -- ./deploy.shThe command’s output, stderr, and exit status are passed back to the caller
verbatim. -t/--timeout is a per-command timeout in seconds and defaults
to 30 — raise it for anything long-running, or the command is cut off
mid-run. Use --json when the caller needs a structured payload instead of
pass-through, and verify that the selected target is served by this host before
using the command in automation.
Scope
For interactive cross-host access, the target must have joined the fleet, be
running, and be reachable at its configured remote-terminal address. For one-shot execution,
the target must be served by this host’s embedded relay. cmdop start makes
the current machine available; it is not an alias for cmdop connect.
Related
- cmdop machines — inventory across every fleet.
- cmdop fleet — chat with a remote agent instead of attaching a terminal.
- Remote machines