I am not sure if anyone here have tried this. I am running Ubuntu to run the node through docker. I have 2 network cards installed and I have 2 public ip addresses, with 2 different gateways, one for each of the network interface, I am wondering if it is possible to run two nodes on the same hardware and utilize the 2 internet access. One internet access for each of the nodes. I am not so sure how docker would handle it, I am very new to docker. Any suggestions are highly appreciated. Thank you.
Assuming that the public IP addresses are routed directly to your host, you should be able to do this with different listen addresses in your
docker run command. So for node 1, your command might look like:
docker run -d --name storj01 \ ... \ -p <address 1>:28967:28967 \ ... \ storjlabs/storagenode
For node 2, you would run something like:
docker run -d --name storj02 \ ... \ -p <address 2>:28968:28967 \ ... \ storjlabs/storagenode
If the public IPs are at a router, you may need to use something like 1:1 NAT at the router to translate them to specific private addresses, and then you could use the above with those private addresses.
Thanks. I will post the complete steps here, including the routing table once I implemented it.
It’s possible, making it work with multiple routing tables is just as easy as it would be for a normal linux router with two uplinks.
That said, I found no clean way of dealing with docker networking, so in order to keep it simple I decided to spin a second VM for docker containers sitting in a different network.