Mercurial > hg > rlgwebd
view rlgwebd-stop.js @ 194:5483d413a45b
RLGWebD: move the control socket into /var/run.
This is a more standard location. /run is preferred by systemd, but
portability to non-systemd systems is important.
author | John "Elwin" Edwards |
---|---|
date | Thu, 14 Jan 2016 19:10:46 -0500 |
parents | 80ca029f0906 |
children |
line wrap: on
line source
#!/usr/bin/env node var net = require('net'); var sockpath = "/var/run/rlgwebd.sock"; var sock = net.connect(sockpath, function () { sock.on('close', function () { if (process.argv[2] == "debug") console.log("Control socket closed"); }); sock.write("quit\n"); });