Mercurial > hg > rlgwebd
comparison 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 |
comparison
equal
deleted
inserted
replaced
193:80ca029f0906 | 194:5483d413a45b |
---|---|
1 #!/usr/bin/env node | 1 #!/usr/bin/env node |
2 | 2 |
3 var net = require('net'); | 3 var net = require('net'); |
4 var sockpath = "/var/local/rlgwebd/ctl"; | 4 var sockpath = "/var/run/rlgwebd.sock"; |
5 | 5 |
6 var sock = net.connect(sockpath, function () { | 6 var sock = net.connect(sockpath, function () { |
7 sock.on('close', function () { | 7 sock.on('close', function () { |
8 if (process.argv[2] == "debug") | 8 if (process.argv[2] == "debug") |
9 console.log("Control socket closed"); | 9 console.log("Control socket closed"); |