On this page

SSH sessions: two boundaries in Keragi

Last updated: 2026-11-20

Keragi offers two SSH modes with different connection and execution locations. Do not mix them up:

EntryWhere it connects / executesWhat it is for
Direct SSH terminal (connector detail page / the “SSH terminal” entry in Connect (Contacts))The connector host SSHes to the LAN/private host you enter; commands run on that targetOperating individual LAN servers, full-screen programs such as vim/top, several tabs
SSH conversation (“SSH conversation” in New conversation, provider ssh)The conversation’s shell runs on the connector host itself (loopback), not on an SSH target; commands run with the connector host’s identityBinding a subaccount as the terminal executor so it receives commands in msgx private chats/groups and returns output

Both entries require approval on the connector host, and neither is a public remote-access product or a bastion replacement.

1. What it does

CapabilityCurrent support
Direct connection to a LAN/private-network host (Linux, or a Windows target with OpenSSH Server)Supported (private addresses only)
Run commands and full-screen TUIs on the direct target (e.g. vim/top)Supported
Resize the terminalSupported
Multiple terminal tabs (one independent direct session each)Supported (tabs stay on this device only)
Create an ssh conversation and bind a subaccount in its detailsSupported (the shell runs on the connector host)
Run commands through a bound subaccount in msgx private chats/groups (direct in private, mention required in a group)Supported (output is not retained)
Public SSH, SFTP, port forwarding, X11 forwardingOut of current scope
Store SSH passwords or private keys in KeragiOut of current scope
Replay terminal scrollback across restartsOut of current scope

2. Prerequisites

Keragi does not store SSH passwords or private keys. The direct terminal uses the connector host’s existing method (key or ssh-agent); host keys are checked with the original hostname, and ~/.ssh/config ProxyJump/ProxyCommand is not used.

3. Direct terminal (LAN host)

  1. Open the Direct SSH terminal from the connector detail page, or the “SSH terminal” entry in Connect (Contacts).
  2. Enter the target’s LAN address, port (default 22) and user.
  3. The session starts in waiting for local approval; open the approval page on the connector host and confirm. No connection to the target and no output stream is opened before approval.
  4. The terminal opens and you can type commands.

On the terminal page:

4. SSH conversation proxy (connector host)

State the boundary first: commands here do not run on the LAN host you would enter in the direct terminal, and they do not SSH to that host. An ssh conversation’s terminal is created by the connector with a loopback target on the connector host itself; commands run with that host’s permissions and identity. To operate a LAN host, use the direct terminal in section 3.

An SSH conversation can bind one subaccount as its terminal executor. Once bound, commands the subaccount receives in any msgx private chat or group it is in are ordinary chat messages: the connector writes them into the conversation’s local shell on the connector host, and output returns through the msgx stream to the originating conversation as an expandable terminal card. The msgx room itself no longer has a terminal menu or a terminal composer.

Prerequisite: first create an “SSH conversation” in New conversation, then bind the subaccount in the SSH conversation’s Conversation details. One SSH conversation has at most one subaccount, and a subaccount holds only one role at a time (terminal executor or AI agent). An unbound or revoked binding, and channel conversations, never run commands. Once bound: in private chat every non-blank message is executed as a command; in a group only a message that mentions the bound subaccount is a command, and text without a mention stays ordinary chat.

Usage:

  1. Open the SSH conversation’s Conversation details, pick one of your subaccounts and confirm the bind. The drawer shows the bound subaccount and its status, and lets you unbind at any time.
  2. Private chat: every non-blank message is one command line. Send /terminal to start a shell and /exit to end it. There is no “ordinary chat” mode with a terminal-identity subaccount.
  3. Group: every command must mention the bound subaccount; the command is the text after the mention, e.g. @ops /terminal or @ops df -h. Group text without a mention stays ordinary chat and is never executed.
  4. Output appears in the originating conversation as one expandable “Terminal session” card, visible to every member. Terminal output is not retained: it exists only in the current page’s memory, and a refresh or re-entry starts the card empty.

Limitations to know:

5. Security and boundaries