Hi,
I'm trying to build something as follows:
An NGINX server is to be run with following features (say on 70.0.0.1):
* Should by default only listen on 70.0.0.1:80/endpoints
* Should allow addition and removal of endpoints.
* An endpoint can be :
TCP_FORWARDER: forwards all TCP traffic on dynamic_port_x to machine_y:port_z
HTTPS_FORWARDER: forwards all traffic on dynamic_port_x to http on machine_y
* An endpoint can be severed, and the dynamic_port_x assigned will be closed, allowing no further traffic to be proxied via it.
* Write/Read endpoint data to sqlite or csv file, so the configuration would survive an nginx restart.
* Though ideally -- the endpoints API would create/sever connections, and nginx would never have to be restarted.
Would it be possible to use openresty to write such and endpoint, and dymanically create/sever connections? I'm looking for pointers to specific lua API I would have to use for the points listed above.
Thank you,
Anil