Skip to content

container-with-xterm runs sshd inside the container and expose shell with "xterm.js".

License

Notifications You must be signed in to change notification settings

hrkt/container-with-xterm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

container-with-xterm

Quick Description

It does

container-with-xterm runs sshd inside the container and expose shell with "xterm.js".

It does not

  • secure anything
  • limit anything

future work

see GitHub project

How to run

  1. build container
docker build -t container-with-xterm .
  1. run it
$ docker run -it -p 3000:3000 --rm container-with-xterm 

> container-with-xterm@0.0.1 start /
> NODE_ENV=prod node app.js

Node.js is listening to PORT:3000
  1. open your brouser http://localhost:3000

terminal

  1. to stop, press Ctrl-C on the terminal you used in step 2.

How it works

These components are running in one container.

[Browser with Terminal(xterm.js)] <---WebSocket(socket.io)---> [Server(Express.js with Socket.io)] ---ssh(ssh2.js)---> sshd

prerequisites

  • Docker

usage

run in dev mode

npm run dev

run in release mode

npm start

build container

docker build -t container-with-xterm .

License

MIT

About

container-with-xterm runs sshd inside the container and expose shell with "xterm.js".

Resources

License

Stars

Watchers

Forks

Packages