You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Support backends listening on UNIX domain sockets #152
UNIX sockets are pretty commonly used for backend services which run on the same server, especially when security is a concern, as they make it easy not to give the backend network access and control which services/users may connect to the backend.
As for #151, I would happily contribute the code for this, assuming it is OK and assuming I manage to find my way around the codebase. :)
To sum up, it's doable, but you'll spend a lot more time on updating the configuration code than on actual network code.
I'll ask that you wait a bit for me to finish #144, since I'm changing a lot of parts of the configuration handling code.
Activity
Geal commentedon Apr 16, 2017
this is doable, but requires changes in a lot of parts of the system.
Backend instances are defined here: https://github.com/sozu-proxy/sozu/blob/master/lib/src/messages.rs#L42
This would probably become an enum and require changes in the other crates as well, to support the new option in configuration.
The part of the code handling connection to the backend is here:
sozu/lib/src/network/mod.rs
Lines 186 to 252 in d7b2dbe
You can use mio-uds to add Unix socket support.
To sum up, it's doable, but you'll spend a lot more time on updating the configuration code than on actual network code.
I'll ask that you wait a bit for me to finish #144, since I'm changing a lot of parts of the configuration handling code.
KellerFuchs commentedon Apr 17, 2017
Sure, thanks.
hongquan commentedon Jan 18, 2020
Please also support Linux abstract namespace socket (which is like Unix domain socket but doesn't create a file in filesystem).
fix(backends): integrate DNS-expanded UNIX sockets
fix(backends): integrate UNIX sockets with header routing