Create syncthing-networking(7)

This commit is contained in:
Stefan Tatschner
2015-05-29 16:45:03 +02:00
parent 0e884a9b65
commit b7c37f330d
+26 -32
View File
@@ -6,29 +6,27 @@ Firewall Setup
Port Forwards Port Forwards
------------- -------------
If you have a NAT router which supports UPnP, the easiest way to get a If you have a NAT router which supports UPnP, the easiest way to get a working
working port forward is to make sure UPnP setting is enabled on both port forward is to make sure UPnP setting is enabled on both Syncthing and the
Syncthing and the router Syncthing will try to handle the rest. If it router Syncthing will try to handle the rest. If it succeeds you will see a
succeeds you will see a message in the console saying: message in the console saying::
::
Created UPnP port mapping for external port XXXXX on UPnP device YYYYY. Created UPnP port mapping for external port XXXXX on UPnP device YYYYY.
If this is not possible or desirable you should set up a port forward If this is not possible or desirable you should set up a port forward for port
for port **22000/TCP**, or the port set in the *Sync Protocol Listen **22000/TCP**, or the port set in the *Sync Protocol Listen Address* setting.
Address* setting. The external forwarded port and the internal The external forwarded port and the internal destination port has to be the same
destination port has to be the same (i.e. 22000/TCP). (i.e. 22000/TCP).
Communication in Syncthing works both ways. Therefore if you set up port Communication in Syncthing works both ways. Therefore if you set up port
forwards for one device, other devices will be able to connect to it forwards for one device, other devices will be able to connect to it even when
even when they are behind a NAT network or firewall. they are behind a NAT network or firewall.
Local Firewall Local Firewall
-------------- --------------
If your PC has a local firewall, you will need to open the following If your PC has a local firewall, you will need to open the following ports for
ports for incoming traffic: incoming traffic:
- Port **22000/TCP** (or the actual listening port if you have changed - Port **22000/TCP** (or the actual listening port if you have changed
the *Sync Protocol Listen Address* setting.) the *Sync Protocol Listen Address* setting.)
@@ -37,29 +35,25 @@ ports for incoming traffic:
Remote Web GUI Remote Web GUI
-------------- --------------
To be able to access the web GUI from other computers, you need to To be able to access the web GUI from other computers, you need to change the
change the *GUI Listen Address* setting from the default *GUI Listen Address* setting from the default ``127.0.0.1:8384`` to
``127.0.0.1:8384`` to ``0.0.0.0:8384``. You also need to open the port ``0.0.0.0:8384``. You also need to open the port in your local firewall if you
in your local firewall if you have one. have one.
Tunneling via SSH Tunneling via SSH
~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~
If you have SSH access to the machine running Syncthing but would rather If you have SSH access to the machine running Syncthing but would rather not
not open the web GUI port to the outside world, you can access it open the web GUI port to the outside world, you can access it through a SSH
through a SSH tunnel instead. You can start a tunnel with a command like tunnel instead. You can start a tunnel with a command like the following::
the following:
::
ssh -L 9999:localhost:8384 machine ssh -L 9999:localhost:8384 machine
This will bind to your local port 9999 and forward all connections from This will bind to your local port 9999 and forward all connections from there to
there to port 8384 on the target machine. This still works even if port 8384 on the target machine. This still works even if Syncthing is bound to
Syncthing is bound to listen on localhost only. listen on localhost only.
You can forward multiple ports corresponding to many machines this way, You can forward multiple ports corresponding to many machines this way, but
but because Syncthing uses session cookies for the entire domain (i.e. because Syncthing uses session cookies for the entire domain (i.e. your local
your local machine), you will need to connect to each control panel in a machine), you will need to connect to each control panel in a separate browser
separate browser instance or explicitly issue a browser reload when instance or explicitly issue a browser reload when switching between them.
switching between them.