synology的NAS提供了很方便的穿牆服務(Quick connect)
但是只能有 web. 如果要用到ssh 的話該怎麼辦呢?
好險有docker
1. install docker
2. start docker, go to 'image', select 'add' -> 'add from url'. in repository name put 'debian'. When asked for variant - pick pretty much any you want. I chose testing-slim
3. once (2) completes, click on the image and select 'launch'. not sure how relevant this is, but i gave my container administrative privileges.
4. go to 'container' tab. find newly created container. click 'details'. last tab is your terminal
5. execute: 'sudo apt-get update' followed by 'sudo apt-get install ssh tmux'
6. (optional) add your private ssh key by executing: "ssh-add - <<EOF", pasting your key and typing "EOF"
7. use SSH remote port forwarding while you ssh back to your machine, eg: ssh -R 1080:<router-ip>:80 username@machine-you-log-in-from
8. on machine you log in from (your actual computer you're sitting by) open web browser and navigate to port 1080.
這樣就能很帥氣的在web 有ssh 了!!
留言列表