Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I make an interactive SSH Terminal inside React?

What I'm trying to do is to make an interactive Web-SSH Terminal which auto-connects to a specified server using keybased-auth.

I found some projects which do exactly that: https://github.com/huashengdun/webssh

The problem is that I cannot directly include that in my existing React project as everything I found runs on an own "server instance" and using iframes is not really an option. I also had a look at ssh2 but that really only is an ssh client, not an interactive terminal as far as I see. Is there any similiar project available like webssh which I can directly implement as a npm-dependency and use it directly in my code? Or how can I make an interactive terminal else?

like image 557
Felixkruemel Avatar asked Aug 15 '26 02:08

Felixkruemel


1 Answers

You could try daffi-terminals

The JavaScript code consists of just 200 lines, making it straightforward to migrate to React. However, it does not utilize the ssh API.

like image 111
Vladimir Boyko Avatar answered Aug 17 '26 15:08

Vladimir Boyko



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!