DEV Community

Discussion on: This is how I turned my old laptop into a server.

cristaldo profile image
Rafael Cristaldo

When you say "From other networks" I guess you are saying "Connect to your server through the Internet".
You have a server at home and want to connect to it from anywhere. You have to configure port forwarding into your ISP Router/Modem.
For example:
1) At your server configure SSH service listening 2222 port in the file /etc/ssh/sshd_config. Restart the ssh service
If you have a firewall you have to configure this port to be allowed with TCP protocol

2) At your Router/Modem ISP appliance, you have to login into it and look for "Forwarding ports"
configure all incomming connection to the 2225/tcp port TO be redirect to your Server IP:2222/tcp...ex: port 2222 (SSH)
Remember to configure your IP Address as a static mode.

If you use no-ip, it's simple to remember your domain name. So you just have to try to connect
ssh -p 2225
The Router will redirect inside your server.
There are many good documents on the internet showing this kind of setup.