forked from bigbluebutton/bbb-webrtc-sfu
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathserver.js
29 lines (22 loc) · 866 Bytes
/
server.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
/*
* Lucas Fialho Zawacki
* Paulo Renato Lanzarin
* (C) Copyright 2017 Bigbluebutton
*
*/
'use strict';
const ConnectionManager = require('./lib/connection-manager/ConnectionManager');
const HttpServer = require('./lib/connection-manager/HttpServer');
const server = new HttpServer();
const WebsocketConnectionManager = require('./lib/connection-manager/WebsocketConnectionManager');
const Logger = require('./lib/utils/Logger');
const ProcessManager = require('./lib/ProcessManager.js');
const PM = new ProcessManager();
PM.start();
const CM = new ConnectionManager(PM.screenshareProcess, PM.videoProcess, PM.streamProcess);
let websocketManager = new WebsocketConnectionManager(server.getServerObject(), '/bbb-webrtc-sfu');
CM.setHttpServer(server);
CM.addAdapter(websocketManager);
CM.listen(() => {
Logger.info("[MainProcess] Server started");
});