Description of feature:
Add SO_REUSEPORT and SO_REUSEADDR support.
luasosket already support it:
sock:setoption("reuseaddr", true)
sock:setoption("reuseport", true)
Motivation: (Why?)
I have nginx that listen:
0.0.0.0:5280, [::]:5280
0.0.0.0:5281, [::]:5281
and prosody that listen:
127.0.0.1:5280, [::1]:5280
127.0.0.1:5281, [::1]:5281
If nginx starts before prosody - than prosody fails to bind ports.
If prosody starts first - all works as expected.
sock:setoption("reuseport", true) - should allow prosody to bind port.
Description of feature: Add SO_REUSEPORT and SO_REUSEADDR support. luasosket already support it: sock:setoption("reuseaddr", true) sock:setoption("reuseport", true) Motivation: (Why?) I have nginx that listen: 0.0.0.0:5280, [::]:5280 0.0.0.0:5281, [::]:5281 and prosody that listen: 127.0.0.1:5280, [::1]:5280 127.0.0.1:5281, [::1]:5281 If nginx starts before prosody - than prosody fails to bind ports. If prosody starts first - all works as expected. sock:setoption("reuseport", true) - should allow prosody to bind port.