From 8ab551a96cdc24f54025e1b2e905a4aadeb76b19 Mon Sep 17 00:00:00 2001 From: Marvin Borner Date: Mon, 11 Feb 2019 21:51:13 +0100 Subject: Added deployment server script --- src/server.js | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 src/server.js (limited to 'src') diff --git a/src/server.js b/src/server.js new file mode 100644 index 0000000..d3c0760 --- /dev/null +++ b/src/server.js @@ -0,0 +1,18 @@ +/* + * server.js + * Copyright (c) 2019, Texx + * License: MIT + * See https://github.com/texxme/Texx/blob/master/LICENSE + */ + +/** + * This script should only be used on a deployment server. For debugging purposes please use 'npm run dev' + */ +const PeerServer = require('peer').PeerServer; +const server = PeerServer({ + debug: true, + port: 4242, + path: '/api', +}); + +server.on('connection', id => console.log('New connection: ' + id)); -- cgit v1.2.3