Re: server: listening on two ports at the same time
Antonio Quartulli <[email protected]> Thu, 19 Mar 2026 10:41:47 +0100
| Newsgroups | gmane.network.openvpn.user |
|---|---|
| Message-ID | <[email protected]> |
Hi, On 19/03/2026 10:18, Gert Doering wrote: > Hi, > > On Thu, Mar 19, 2026 at 10:08:45AM +0100, Antonio Quartulli wrote: >> On 18/03/2026 23:55, Greg Troxel wrote: >>> (It would be great if someone could do a blog post or docs change to >>> explain how to configure nginx to function as a proxy to reach an >>> openvpn server on the same host, so that the connection from the client >>> to the server would just be on 443/tcp. Critically, this should work >>> without interfering with the web server, so no remapping /.) >> >> It sounds as if you are looking for the --port-share option? >> It's been there for a while (way before multisocket was implemented) and it >> seems to be what you are looking for. > > I think he wants it the other way round - connections go to nginx, and > *if* openvpn, then forward to openvpn. Ah. This would require nginx to be able to detect OpenVPN packets and forward them accordingly. Not sure this can be done at all. > > No idea if this can be done today - there are some patches floating around > to add various aspects of PROXY PROTOCOL, so maybe it can, maybe not. Those patches waiting review are only about parsing the Proxy Protocol header that is prepended to a packet after it went through some CloudFlare machinery. Regards, -- Antonio Quartulli