unifi-utilities / unifios-utilities

A collection of enhancements for UnifiOS based devices
GNU General Public License v3.0
3.95k stars 419 forks source link

need help: nspawn custom container w. isolated macVLAN, now want VLAN to talk to other internal networks #592

Closed Flying-Ace closed 9 months ago

Flying-Ace commented 9 months ago

UDMP OS 3.2.9, Network 8.0.28, Hi all, need help with networking the container setup to the main network(s).
https://github.com/unifi-utilities/unifios-utilities/tree/main/nspawn-container I used step 2a (isolated macvlan) to get adguard running because i wanted it on its on ip/subnet and that is how the example instructions recommended. currently the container can be reached by all client networks but the container can not reach any of the clients networks other than the gateway 192.168.1.1. The reason for the ask is that I installed tailscale on the container and want all network-subnets to talks. ( a firewall rule was applied, but didnt help ), I suspect I need a macvlan bridge to the router netwk 192.168.1.0/24 but dont know how to go about that.

i also tried to install tailscale on the outside of the container (ie: unifi-os) to skip the networking the container issues, however the package did download and install, but couldnt bring up tailscale session (commands: tailscale up, tailscale login).

suggestions? (TIA)

mlebaugh commented 9 months ago

So I ran across this issue as well. It seems that this has been fixed but the documentation is out of date. You also need to enable dnsmasq to listen on the container network.

If you followed steps in the code blocks here: https://github.com/unifi-utilities/unifios-utilities/tree/main/nspawn-container

Steps 2A, 1 has a curl command to @peacey 's original boot script. You want this one which is linked just above: https://github.com/unifi-utilities/unifios-utilities/blob/main/nspawn-container/scripts/10-setup-network.sh

Found this from this issue: https://github.com/unifi-utilities/unifios-utilities/issues/510 which linked to this pull request. https://github.com/unifi-utilities/unifios-utilities/pull/550