Closed kalekseev closed 4 years ago
I don't think this is good to dynamically select ports. I think things should be predictable. If a user starts his Procfile, and his Rails app is bint to port 5000, it should always be bint to 5000. Otherwise, it will confuse and frustrate the user.
Sure the decision is up to you, I prefer to have app started rather than interrupted by the fact that the port is allocated by someone, the idea to search for a port was taken from https://pypi.org/project/honcho/ - python implementation of the foreman.
How is this supposed to be working? I tried it with the following snipped but when I tried to start the second database in another directory it complained that the port 5000 was already used. I would like the user to be able to start as many instances as he wants in parallel.
db: postgres -p $PORT
@Nebucatnetzer You can configure the way Overmind sets the PORT
variable: https://github.com/DarthSim/overmind#specifying-the-ports
I’ve seen that. So overmind doesn’t check if the port is available globally on the system?
Overmind should pass only available port numbers otherwise the user experience is bad, if port is in use by some proc then try next (up to 3-5 tries).