The matlab-proxy-app creates a web server that OOD app can redirect to.
Now, we are wondering if we can set this up to work within a limited port range? Is there a way on the OOD side to limit to a port range and provide this over to the matlab-proxy-app as the port to launch with? This might allow for a limited firewall rule to support matlab-proxy.
really is just a convenience method defined by OOD to find an available, open, port number. You could do whatever you want here, defining a custom thing if you want as long as it produces an appropriate port number, but this function is really good as it checks if the port is in used, and will pick another if so.
Better yet, it already supports exactly what you ask for via optional argument 2 and 3:
port=$(find_port ${host} 6000 6010)
if you wish to have it limited to a just a few ports.
Documentation here:
edit: oh i just now noticed that the min_port and max_port default values can also be directly configured in the batch_connect yml
so i guess just do that instead of fiddling with the scripts.