lstn

0.0.2 • Public • Published

lstn

lstn makes it more straightforward to listen on unix sockets by deleting old sockets when present and setting the mode of the created socket file.

Usage

lstn(server, socket[, mode][, callback]);

 
// Instead of
server.listen("/path/to/socket.sock", function(err){ /* ... */ });
 
// do it like this
var lstn = require("lstn");
 
lstn(server, "/path/to/socket.sock", 0o777, function(err){ /* ... */ })
 

When you use port and hostname arguments instead, they just get passed through.

Readme

Keywords

Package Sidebar

Install

npm i lstn

Weekly Downloads

1

Version

0.0.2

License

Unlicense

Unpacked Size

2.36 kB

Total Files

3

Last publish

Collaborators

  • yetzt