-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathserver.js
More file actions
23 lines (22 loc) · 771 Bytes
/
server.js
File metadata and controls
23 lines (22 loc) · 771 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
var port = process.env.APP_PORT||8888
, io = require('socket.io').listen(port)
, SSWEBOpts = {
host : process.env.SS_WEB_HOST||'localhost'
, port : process.env.SS_WEB_PORT||80
}
, httpHelper = require('./modules/httpHelper').configure(SSWEBOpts)
, chat = require('./modules/chat').load(io,httpHelper)
, suda = require('./modules/suda').load(io,httpHelper);
io.configure(function(){
io.set('log level', 0);
io.set('transports', [
'websocket'
, 'flashsocket'
, 'htmlfile'
, 'xhr-polling'
, 'jsonp-polling'
]);
});
console.log('Server start... port['+port+']');
console.log('springsprout server host ['+SSWEBOpts.host+']');
console.log('springsprout server port ['+SSWEBOpts.port+']');