Sign inSign up

kosmos367/socket.io-gateway

By kosmos367

•Updated almost 7 years ago
Archived

Image
0

184

kosmos367/socket.io-gateway repository overview

⁠Realtime gateway

⁠How it works

  1. Install dependencies with yarn (or npm)

  2. Run the service with node app/index.js

  3. Connect from socket and join the rooms you want to listen to and add event hooks:

  var mySocket = io();
  mySocket.emit('join', 'my-room');
  mySocket.on('echo', function(e) { console.log('my-room echo', e); });
  1. POST events to /events/<room>/<event>, the event will be forwarded to the connected sockets.

⁠Monitoring

  • There's a log available in /log
  • There are stats with the timestamp for the last message for each room in /stats
⁠Docker

A docker image is available:

  • Run docker run -d -p 5005:5005 zoomeranalytics/socket.io-gateway:1.0.1 node index.js

Tag summary

Content type

Image

Digest

Size

284.3 MB

Last updated

almost 7 years ago

docker pull kosmos367/socket.io-gateway