Skip to content

mise bootstrap remote exec ​

  • Usage: mise bootstrap remote exec [FLAGS] [TARGET]… <-- COMMAND>…
  • Source code: src/cli/bootstrap.rs

Run one command on inventory hosts over SSH

Selects hosts from [bootstrap.remote.hosts] the same way mise bootstrap remote does (by name, --tag, or --all, plus any --host destination) and connects with the same SSH settings: the host's user, port, identity file, and ssh_options. Nothing is uploaded and mise is not needed on the host.

Each word after -- reaches the remote shell quoted, so arguments arrive as given; pipes or redirection need an explicit sh -c '...'. Stdin is forwarded, so a secret can be piped in without appearing in the command.

Hosts run one after another unless --parallel is given. With more than one host, each output line starts with the host's name (except with -t, where output goes straight to the terminal), piped stdin is sent to every host, and a summary lists each host's exit status. With one host, mise exits with the command's status.

exec is a subcommand name, so mise bootstrap remote exec never bootstraps an inventory host named exec.

Arguments ​

  • [TARGET]… — Inventory host names from [bootstrap.remote.hosts]
  • <-- COMMAND>… — Command and arguments to run on each host, after --

Flags ​

  • --all — Select every inventory host

  • --tag <TAG> — Select configured hosts with this tag; repeat to match any tag

  • --host <[USER@]HOST> — SSH destination that is not in the inventory ([user@]host); repeat for more

  • --sudo — Run the command with sudo on each host

  • -t --tty — Allocate a terminal on the host, for prompts such as sudo's password

    Output is not prefixed with host names, since a prompt needs the terminal as it is. Only takes effect when stderr is a terminal.

  • --parallel — Run on every selected host at once instead of one after another

  • --connect-timeout <SECONDS> — SSH connection timeout in seconds

    Default: 10

  • -i --identity-file <PATH> — SSH identity file, overriding the inventory and SSH config

  • --port <PORT> — SSH port, overriding the inventory and SSH config

  • --ssh-option <OPTION> — OpenSSH -o option; repeat for multiple options

  • -h --help — Print help

Examples ​

Run a command on one inventory host

mise bootstrap remote exec mac1 -- uptime

Inspect a LaunchDaemon on every host tagged mac-ci

mise bootstrap remote exec --tag mac-ci --sudo -- launchctl print system/dev.mise.ci.actions-runner

Allocate a terminal so sudo can ask for a password

mise bootstrap remote exec mac1 --sudo -t -- softwareupdate --install --all

Pipe a secret to the host without putting it in the command

gh auth token | mise bootstrap remote exec mac1 -- sh -c 'umask 077; rm -f ~/.runner-token; cat > ~/.runner-token'

Run on every inventory host at once

mise bootstrap remote exec --all --parallel -- sw_vers -productVersion
MIT LicenseCopyright © 2026jdx.dev