Asrosema Posted April 23, 2019 Share Posted April 23, 2019 Hey all! So I followed SpaceInvader's video on how to setup a Ubuntu server VM running a VPN (PIA in my case) and I'd like to be able to route traffic from Dockers through the VM. I was able to get a VLAN setup but I'm stuck and have a few questions: I think I'm supposed to set the Gateway of the VLAN to the IP address of the VM, is that correct? Doesn't the VLAN need to be with a different 3rd number on my network? So normally it's X.X.34.X and the VLAN is for X.X.50.X. So is the gateway supposed to be X.X.50.1 or X.X.34.VMip? Do I need to add or change the network bridge in the VM? Will I have the orignal br0 AND br0.50 or do I need to swap out the original brige for the VLAN bridge. I tried adding it so there was two thinking, Docker to VM and then VM to internet routes but that didn't seem to work, unless I'm missing adding a route somewhere? Any help would be appreciated! Thanks! Quote Link to comment
ken-ji Posted April 23, 2019 Share Posted April 23, 2019 Both the VM and container need to be on the same VLAN and hence the same subnet. so if the container is x.x.50.y -> the gateway should be x.x.50.1 (which definitely has to be an IP of the VM) Quote Link to comment
Asrosema Posted April 24, 2019 Author Share Posted April 24, 2019 So setting up the vlan if static is X.X.50.2 the gateway is X.X.50.1 The VM just needs to be any IP on the subnet (x.x.50.220) or the VM IP needs to be the gateway address (x.x.50.1)? Quote Link to comment
ken-ji Posted April 24, 2019 Share Posted April 24, 2019 the VM has to be the gateway as its the one to route the container out. Quote Link to comment
Asrosema Posted April 24, 2019 Author Share Posted April 24, 2019 (edited) Do I need to have settings on my router too? I thought setting it up via unRAID this way it did all the routing through unRAID and it doesn't require specific hardware? Something still isn't working. Here's some screenshots of the setup. But the tunnel doesn't start up in the VM and I can't ping anything. Route info VLAN info VM bridge IP config in VM Edited April 24, 2019 by Asrosema Quote Link to comment
ken-ji Posted April 24, 2019 Share Posted April 24, 2019 Haven't watched the video, but a VM for VPN access typically has 2 network interfaces - one on the regular network and another for the VLAN/subnet that will be given VPN "protection" outwards. Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.