Novage / wt-tracker

High-performance WebTorrent tracker
Apache License 2.0
248 stars 87 forks source link
bittorrent bittorrent-tracker p2p p2p-media-loader p2p-network peer-to-peer torrent tracker webrtc websockets webtorrent

Build Status Coverage Status

wt-tracker

High-performance WebTorrent tracker.

WebTorrent tracker is a required component of WebTorrent and P2P Media Loader (peer-to-peer networks for web browsers) to do WebRTC signaling - exchanging connection data (i.e. SDP) between peers - joining them into swarms.

Features

Related projects

Build instructions

Node.js 16+ is required.

npm install
npm run build

Run instructions

./bin/wt-tracker [config.json]

or

node lib/run-uws-tracker.js [config.json]

or

npm start [config.json]

Configuration

See config.json

Name Type Description
servers.websockets.path string URL pattern for the WebSockets endpoint
servers.websockets.maxPayloadLength number The maximum length of received message
servers.websockets.midleTimeout number The maximum amount of seconds that may pass without sending or getting a message. Being idle for more than this, and the connection is severed.
servers.websockets.compression 0,1,2 0 = no compression, 1 = shared compressor, 2 = dedicated compressor (see details)
servers.websockets.maxConnections number The maximum number of WebSocket connections. 0 = no limit.
tracker.maxOffers number The maximum number of client's WebRTC SDP offers that are processed
tracker.announceInterval number Desired announce interval in seconds required from the clients

Index HTML page

You can specify a content of the index page by creating index.html file in the working directory.