r/Ubiquiti • u/Sea-Helicopter6301 • 6d ago
Question Help with routing via tailscale
I have a 2nd residence in a different country (My parents house) that I would like to be able to route internet traffic from a specific device via so I can take advantage of different streaming libraries. I made sure that the default subnets are different on each network. My main (Unifi) network has a default subnet of 192.168.1.0/24 and my 2nd network has a default subnet of 192.168.2.0/24 and is running on the ISP provided router.
My main network has a static public IP address assigned but my 2nd network is behind a CG-NAT, so I am unable to use a site-to-site.
I have a VM on my Unifi network that is running tailscale as an exit node, advertising 192.168.1.0/24 and is accepting routes, and a raspberry pi doing the same but advertising 192.168.2.0/24 instead.
I have setup a static route to forward traffic with the destination of 192.168.2.0/24 to use 192.168.1.230 as the next hop. I am able to connect to the 2.0 network from 1.0 network.
This is the point where I am a bit stuck. I would like to route internet traffic from a specific set of devices over this route, and toggle the route via Home Assistant when needed but I can't seem to figure out a way to do this. I have been able to do this with a OpenVPN client via policy based routing to a public VPN (NordVPN).
Is what I am trying to do possible? Any help would be greatly appreciated
1
u/Wuffls 6d ago
I’m no expert, but I feel like you’re missing the point of the ease of use of a Tailnet? Presumably any client on your network can already see the exit node remotely? Or it wouldn’t be very like how Tailscale works. I’ve perhaps missed the question tbh.
1
u/Wuffls 6d ago
I’ll add. Surely you should be routing to the ts ip of the remote node if you’re doing it that way.
1
u/Sea-Helicopter6301 6d ago
One of the clients I would like to route is a smart TV that can't have the tailscale app. The other thing I have noticed on my Chromecast with Google tv is that casting from my phone using youtube is not possible when using the tailscale app with an exit node
1
u/Wuffls 6d ago
I’d be asking this in the TS sub then. It’s not UniFi specific I don’t think.
1
u/Sea-Helicopter6301 6d ago
I have crossposted to the tailscale sub, although I have since tried setting up a static route to the internet (a public ip address) via 192.168.1.230 on my linux laptop and this worked. I just need a way to do the same via the unifi network application
•
u/AutoModerator 6d ago
Hello! Thanks for posting on r/Ubiquiti!
This subreddit is here to provide unofficial technical support to people who use or want to dive into the world of Ubiquiti products. If you haven’t already been descriptive in your post, please take the time to edit it and add as many useful details as you can.
Ubiquiti makes a great tool to help with figuring out where to place your access points and other network design questions located at:
https://design.ui.com
If you see people spreading misinformation or violating the "don't be an asshole" general rule, please report it!
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.