This is an old revision of the document!
WeTTY
NOTE: i don't use WeTTY anymore, this page might get outdated over time.
WeTTY it's a web based terminal to your server.
Due to a bug in the latest version (2.7.0) (see issue here) you need to install 2.6.0.
Installation
First of all, you need sshpass for password login to work with WeTTY:
emerge sshpass
(doesnt seems to be working anyway)
Now, as usual, create a dedicated user since it's not safe to run WeTTY as root:
useradd -m wetty
Now install npm locally:
su - wetty curl -sL https://raw.githubusercontent.com/nvm-sh/nvm/master/install.sh | bash source .bashrc nvm install 20 npm -g i wetty@2.6.0 ssh-keygen
Reverse Proxy
- wetty.conf
location ^~ /wetty { proxy_pass http://127.0.0.1:5522/wetty; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "upgrade"; proxy_read_timeout 43200000; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header Host $http_host; proxy_set_header X-NginX-Proxy true; }
Start & Autostart
start:
wetty --host 127.0.0.1 --port 5522 --ssh-key ~/.ssh/id_ed25519 --ssh-host localhost --ssh-user myuser --ssh-auth publickey