Skip to content

WIP: feature/SSH#136

Draft
alexanderbh wants to merge 29 commits intotogglebyte:mainfrom
alexanderbh:feature/ssh
Draft

WIP: feature/SSH#136
alexanderbh wants to merge 29 commits intotogglebyte:mainfrom
alexanderbh:feature/ssh

Conversation

@alexanderbh
Copy link

@alexanderbh alexanderbh commented Jul 18, 2025

Adds an Anathema SSH server that can serve Anathema apps to client SSH connections.

No breaking changes to existing code.

Changes to exisiting code

  • Adds a new way to create a Backend which takes in the "output"/Writer. So it is not hardcoded to stdout.
  • Added more modifier keys to the Key event (maybe needs to be mapped from crossterm as well)

New code

  • Added a feature "ssh" for this. Not sure if this is needed since you just don't use the SSH server if you don't need it
  • anathema-ssh crate which exposes the AnathemaSSHServer and SSHBackend
  • SSHBackend is a think wrapper on TuiBackend but instead of reading events from crossterm (stdin) it directly pop events from the event queue
  • AnathemaSSHServer takes in a "runtime factory" which is a function that will start the runtime. This is called for each new client.
    • It is therefore the AnathemaSSHServer that instantiates the SSHBackend for each client. It will hook it up with the SSH sesession. The runtime factory then get's the new SSHBackend instance.

Demo:

Screen.Recording.2025-07-16.at.19.28.01.mov

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant