mise bootstrap ssh
- Usage:
mise bootstrap ssh <SUBCOMMAND> - Effect: read-only
- Source code:
src/cli/bootstrap.rs
Manage SSH trust from [bootstrap.ssh]
[bootstrap.ssh.authorized_keys.<user>] sets the public keys that may log in as a user, in ~<user>/.ssh/authorized_keys. mode = "ensure" adds the declared keys and keeps the others; mode = "exact" removes every key the config does not declare, after saving the old file next to it. [bootstrap.ssh.config] keeps Host entries in a marked region of your ~/.ssh/config and leaves the rest of the file alone.
Over SSH, or under sudo, an exact entry for the user you log in as is refused when none of its keys is authorized now (or, when sshd exposes it, when the key this session used is not declared), since applying it could lock you out. --force applies it anyway.
Flags
-h --help— Print help
Examples
Exit with status 1 if any SSH entry differs from the config
mise bootstrap ssh status --missingShow the changes, including every key an exact entry removes
mise bootstrap ssh apply --dry-runApply without a prompt
mise bootstrap ssh apply --yes