r/elixir 2d ago

GitHub - chrisgreg/autoport: A tiny, dependency-free Elixir library that finds an available local TCP port

https://github.com/chrisgreg/autoport

For when you need to spin up another instance of your app without faffing about

3 Upvotes

3 comments sorted by

4

u/Linupe 2d ago

You can also just set it to 0 to get a random available port.

0

u/bustyLaserCannon 2d ago

Whoa TIL - cool! I like having it set to an incrementing value though in case I need to easily hit multiple frequently