4 ms·
What do you mean here? If you are referring to network interface, why there is a problem to bind to it?
by jesterson 5y ago
What do you mean here? If you are referring to network interface, why there is a problem to bind to it?
- sgjohnson 5y agoYou can’t bind nginx to a specific network interface. You can bind it to a specific IP address though (and then, by extension, also to an interface, but you need to know the IP).
- jesterson 5y agoThat's right, although I am struggling to think of use cases where you may need to assign it to network interface with dynamic IP allocation (otherwise you'd know the IP beforehand).
- sgjohnson 5y ago> although I am struggling to think of use cases where you may need to assign it to network interface with dynamic IP allocation Some failover configurations come to mind, in particular the one where the box doesn’t get an IP address on the said interface until the failover kicks in, but I don’t know why would anyone run this kind of a setup without NAT.
- egberts1 5y agoI did that bind with DHCP server failover.
- egberts1 5y agoMy use case is simple. I have five disparate IP subnets whose firewall must NOW have to ascertain that ONLY a certain subnet can access this unbinded netdev … in case the NGINX (or any daemon) starts to sniff unwarranted IP subnet traffic. And yes, you can bind to a dynamic IP assigned netdev. And yes , I’ve had to replace NGINX with a web server that can do a netdev bind.