When to choose it
Choose a Docker gateway when the router at the site cannot be the gateway, or when you do not want to change the router, and there is a machine with Docker on the network. Choose a router gateway (a MikroTik, or a small Linux box with the ProxyLink agent) when you need one of the things a container does not do:- No Wake-on-LAN, and nothing else that needs a broadcast. The container sits on its own Docker network, not on your LAN, so it cannot send one.
- At most eight networks, each /20 to /30 (at most 4,094 addresses). See Its networks.
- No gateway console. The preset checks that a MikroTik or Linux gateway offers are not offered here.
- No updates by itself. You replace one line in the Compose file. See Updating.
What the container can and cannot do on the host
The Compose file from ProxyLink is the whole of what the container is given, and you can read it before you start it:- Every capability is dropped except two,
NET_ADMINandNET_RAW. It needs them for its WireGuard connection and for its own firewall rules. no-new-privilegesis set, the container’s file system is read-only, and IP forwarding is switched on inside the container only.- It has one volume, for the key it makes for itself. It has no access to the host’s disks, no Docker socket, it is not
privileged, and it does not run in the host’s network. Started withnetwork_mode: host, it refuses to start and changes nothing on the host.
Add it
In a team, only the owner or a manager can add a gateway.1
Open the form
Go to Devices → + Add device. On a wide screen, choose Docker (a NAS) under A whole network, another way. On a phone, choose Docker gateway. The form Add Docker gateway opens.
2
Fill it in
- Gateway label: a name for the gateway, for example
Office NAS. - Network to reach: the network the Docker host is on, for example
192.168.1.0/24. It must be a private network, /20 to /30. - Let me add more networks later, from ProxyLink. Ticked by default. It puts the agent line in the Compose file. Untick it and the container keeps to the one network above.
- Which client is this for? (in a team, optional): pick a client, or + Create new client.
3
Run it on the Docker host
The form now shows Run this on the Docker host and the Compose file. Click Copy the Compose file.
- TrueNAS SCALE: Apps, Discover Apps, the menu at the top right, Install via YAML. Paste the text.
- Anywhere else: save it as
compose.yamland run:
4
Check that it connected
Read the container’s log:It ends with:Click Done. The gateway is now in your list on the Devices page. Its own page shows the release it runs (“Installed as v0.2.0.”), a section Address translation, and VLAN subnets, where you add more networks.
5
Add services
Add a service for each thing you want to open on the network, as on any other gateway.
The Compose file
This is the file ProxyLink gives you. Your own file has a real image line, your own link and your own network.PROXYLINK_URL again at every start to know where to ask for its networks.
Its networks
The first network is fixed. It is the one written asPROXYLINK_LAN in the Compose file. The container checks ProxyLink’s answer against that line and refuses to start for any other first network. To change it, remove the gateway and add it again.
More networks are added on the gateway’s page. This needs the agent line in the Compose file.
- Open the gateway’s page.
- Under VLAN subnets, enter the network, for example
192.168.40.0/24, and click Add. - The network appears in the list with Waiting for the gateway, up to a minute. The page checks again by itself. When the container has made its rules, the line changes to On the gateway.
Limits
- A Docker gateway carries at most eight networks, the first one included. So you can add seven. Eight is a limit ProxyLink sets for this kind of gateway, not something Docker imposes. A site with more belongs on a router gateway, or on a second Docker gateway.
- Each network is a private range (
10.x,172.16to172.31.x,192.168.x), /20 to /30: at most 4,094 addresses in one network. - Write the network itself, for example
192.168.40.0/24, not an address inside it. - A network may not overlap another network of the same gateway, ProxyLink’s own ranges (
10.100.0.0/16and10.128.0.0/9), or the Docker network the container sits on.
What the page says about each network
When ProxyLink refuses a network
These are shown when you click Add. Nothing is changed.
A network that the gateway already has, and a range that is ProxyLink’s own or in use by another account, are also refused with a sentence that says so.
When the container refuses a network
ProxyLink accepted the network, and the container did not. The network stays in the list with one of these sentences. The container’s log says the same with a short code (see the log page).
A refused network does not affect the others: the container keeps every network it already carries.
Giving the container’s Docker network another range
Docker picks a range for the container’s own network. If that range overlaps one of your networks, the container says so (overlap-docker) and does not take the network. Tell Docker which range to use, one that is nowhere on the site. At the end of the Compose file, replace
docker compose down (without -v, so the volume stays) and docker compose up -d. It is the same gateway, on another Docker range.
Removing a network
Under VLAN subnets, click Remove beside the network. ProxyLink stops sending to it, and the container removes its rules the next time it asks. There is no restart. Removing is refused while a service points into the network. The page says, for example: “2 services on this gateway point into 192.168.40.0/24 (“NVR”, “PBX”). Delete them first, then remove the network.” Delete those services, then remove the network. If you add the same network again later, it gets a new range inside ProxyLink, so its devices get new VPN addresses.Address translation
ProxyLink reaches every network of a gateway through a range of its own, so two sites that use the same network never meet. On a Docker gateway the container makes this rule itself when it starts, so there is nothing to set up: the section Address translation on the gateway’s page shows Your network and Inside ProxyLink. More about it in Overlapping subnets.Updating, restarting, moving, removing
Everything that makes the container this gateway is in its volume: the key it made, and the list of its networks. Keep the volume and it stays the same gateway. Remove the volume and it is a new machine that ProxyLink does not know.Updating the image
The container does not update itself. When a newer release exists, the gateway’s page says so and shows the new image line.- Replace the
image:line in your Compose file with the one shown on the gateway’s page. - Run
docker compose up -dagain.
down -v. The volume keeps the key, so it stays this gateway, with its services. The log starts with the release that runs:
image: line back and run docker compose up -d again. The volume is the same for both releases, so it stays the same gateway. Its log says why a start failed. Going back to v0.1.0 means one network again: that release has no agent and ignores the saved list.
Restarting and rebooting
Nothing to do. Afterdocker restart proxylink-gateway, and after a reboot of the host, the container starts by itself and brings every network back from its volume. If ProxyLink cannot be reached at that moment, it starts with the networks it carried last time.
Moving to another machine
The new machine must be on the same first network. Stop the container on the old machine, bring the contents of the volumeproxylink-gateway-data to the new machine, and start it there with the same Compose file. The old and the new container must never run at the same time.
Without the volume it cannot be moved: the link in the Compose file was used once. Then remove the gateway in ProxyLink and add it again, as a new one. Its services are removed with it and have to be added again.
Switching the agent off
Delete the linePROXYLINK_AGENT: "on" from the Compose file and run docker compose up -d again. The gateway goes back to its first network only; the saved list is ignored. Networks you added stay listed on the gateway’s page as Not known: the gateway is not asking ProxyLink right now, and are not reachable. Remove them there if you no longer want them.
Removing it
- On the gateway’s page, under Remove this device, click Remove device. It is disconnected at once. Its services are removed with it, and any share link to them stops working.
- On the host:
-v removes the volume with the key. To set the same machine up again later, add a new Docker gateway and use the new Compose file.
Coming from v0.1.0
Release v0.1.0 carried one network and had no agent. A gateway installed with it keeps working as it is. To add more networks, change two lines of its Compose file. The gateway’s page shows both under VLAN subnets.- The image line. Replace your
image:line with the image line shown on the gateway’s page. - The agent line. Add this line under
environment:, at the same depth asPROXYLINK_LAN:
PROXYLINK_URL and PROXYLINK_LAN as they are. Then run:
When something is wrong
The container says what it is doing, and what stopped it, in its own log:docker logs proxylink-gateway. Every sentence it can print, with what it means and what to do, is on its own page: Docker gateway: the log and what to do.
Limits, in one place
- Networks: at most eight per gateway, the first included. Each a private range, /20 to /30.
- One network only without the agent line.
- The first network cannot be changed. Remove the gateway and add it again.
- No Wake-on-LAN, and nothing else that needs a broadcast.
- No gateway console.
- No automatic updates. One line in the Compose file, by you.
- The link in the Compose file works once, for 30 minutes.
- The container must run in its own Docker network, never in the host’s.
- Over the VPN, engineers reach the gateway’s networks. Other devices of the same client do not.
- TrueNAS CORE is not supported: it has no Docker.