Deno: Support unix domain sockets

Created on 25 Feb 2020  路  5Comments  路  Source: denoland/deno

Now that UDP support has been added in #3946 I'm wondering if Unix Domain sockets could be added in the same way.

Unix sockets are very handy when you need to communicate with another process without dealing with ports and whatnot.

I suppose the only question is whether connecting to a UDS from Deno requires a net permission or a file permission. My hunch is that it is a file permission, simply because that is how it is thought of in the underlying OS.

Thanks.

feat

Most helpful comment

Here is the API I propose

Deno.listen({ transport: "unix", address: "/var/run/mysocket" }): UnixConn

class UnixConn would be similar to UDPConn and Go's definition https://golang.org/pkg/net/#UnixConn

All 5 comments

Here is the API I propose

Deno.listen({ transport: "unix", address: "/var/run/mysocket" }): UnixConn

class UnixConn would be similar to UDPConn and Go's definition https://golang.org/pkg/net/#UnixConn

@hazae41 are you working on this? I would like to give this a try if you're not :)

@hazae41 are you working on this? I would like to give this a try if you're not :)

Not yet

Hi everyone,

Would you please tell me where I could find the chosen solution.

Thanks,
Juu

Was this page helpful?
0 / 5 - 0 ratings

Related issues

somombo picture somombo  路  3Comments

kitsonk picture kitsonk  路  3Comments

zugende picture zugende  路  3Comments

ry picture ry  路  3Comments

benjamingr picture benjamingr  路  3Comments