It was only Linux and BSDs before, but now with netstack mode, it also works on
Windows and darwin. It's not worth limiting it to certain platforms.
Tailscaled itself can complain/fail if it doesn't like the settings
for the mode/OS it's operating under.
Updates #707
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
upf.StringVar(&upArgs.hostname,"hostname","","hostname to use instead of the one provided by the OS")
ifruntime.GOOS=="linux"||isBSD(runtime.GOOS){
upf.StringVar(&upArgs.advertiseRoutes,"advertise-routes","","routes to advertise to other nodes (comma-separated, e.g. \"10.0.0.0/8,192.168.0.0/24\")")
upf.BoolVar(&upArgs.advertiseDefaultRoute,"advertise-exit-node",false,"offer to be an exit node for internet traffic for the tailnet")
}
upf.StringVar(&upArgs.advertiseRoutes,"advertise-routes","","routes to advertise to other nodes (comma-separated, e.g. \"10.0.0.0/8,192.168.0.0/24\")")
upf.BoolVar(&upArgs.advertiseDefaultRoute,"advertise-exit-node",false,"offer to be an exit node for internet traffic for the tailnet")
ifruntime.GOOS=="linux"{
upf.BoolVar(&upArgs.snat,"snat-subnet-routes",true,"source NAT traffic to local routes advertised with --advertise-routes")
upf.StringVar(&upArgs.netfilterMode,"netfilter-mode",defaultNetfilterMode(),"netfilter mode (one of on, nodivert, off)")