I need a way to proxy_pass
a dynamic port through the location's URL. The proxy has the same IP but the port changes since the servers are created via docker on random port numbers. (Too many for me to add manually)
I need a way to proxy_pass
these URLs and ports dynamically. I was thinking I could some how pass in the port number via URL variable?
Example:
location /$someport/servername/hls/ {
proxy_buffers 16 4k;
proxy_buffer_size 2k;
proxy_pass http://216.189.210.65:$someport;
}
Is there a way I can do this?