2016-01-15 13:46:41 +08:00
// TODO: should be split on server and client side
// // Global configurations file
2016-01-30 09:33:40 +08:00
let config , file , transports , winston ;
2016-01-13 04:15:16 +08:00
config = { } ;
2016-01-15 13:46:41 +08:00
// Default global variables
2016-01-13 04:15:16 +08:00
config . appName = 'BigBlueButton HTML5 Client' ;
config . bbbServerVersion = '1.0-beta' ;
config . copyrightYear = '2015' ;
config . html5ClientBuild = 'NNNN' ;
config . defaultWelcomeMessage = 'Welcome to %%CONFNAME%%!\r\rFor help on using BigBlueButton see these (short) <a href="event:http://www.bigbluebutton.org/content/videos"><u>tutorial videos</u></a>.\r\rTo join the audio bridge click the gear icon (upper-right hand corner). Use a headset to avoid causing background noise for others.\r\r\r' ;
config . defaultWelcomeMessageFooter = ` This server is running a build of <a href='http://docs.bigbluebutton.org/1.0/10overview.html' target='_blank'><u>BigBlueButton ${ config . bbbServerVersion } </u></a>. ` ;
config . maxUsernameLength = 30 ;
config . maxChatLength = 140 ;
config . lockOnJoin = true ;
2016-01-15 13:46:41 +08:00
//// Application configurations
2016-01-13 04:15:16 +08:00
config . app = { } ;
2016-01-15 13:46:41 +08:00
//default font sizes for mobile / desktop
2016-01-13 04:15:16 +08:00
config . app . mobileFont = 16 ;
config . app . desktopFont = 14 ;
2016-01-15 13:46:41 +08:00
// Will offer the user to join the audio when entering the meeting
2016-01-13 04:15:16 +08:00
config . app . autoJoinAudio = false ;
config . app . listenOnly = false ;
config . app . skipCheck = false ;
2016-01-15 13:46:41 +08:00
// The amount of time the client will wait before making another call to successfully hangup the WebRTC conference call
2016-01-13 04:15:16 +08:00
config . app . WebRTCHangupRetryInterval = 2000 ;
2016-01-15 13:46:41 +08:00
// Configs for redis
2016-01-13 04:15:16 +08:00
config . redis = { } ;
2016-03-14 09:46:29 +08:00
config . redis . host = '127.0.0.1' ;
2016-01-13 04:15:16 +08:00
2016-03-14 09:46:29 +08:00
config . redis . post = '6379' ;
2016-01-13 04:15:16 +08:00
config . redis . timeout = 5000 ;
config . redis . channels = { } ;
2016-03-14 09:46:29 +08:00
config . redis . channels . fromBBBApps = 'bigbluebutton:from-bbb-apps:*' ;
2016-01-13 04:15:16 +08:00
config . redis . channels . toBBBApps = { } ;
2016-03-14 09:46:29 +08:00
config . redis . channels . toBBBApps . pattern = 'bigbluebutton:to-bbb-apps:*' ;
2016-01-13 04:15:16 +08:00
2016-03-14 09:46:29 +08:00
config . redis . channels . toBBBApps . chat = 'bigbluebutton:to-bbb-apps:chat' ;
2016-01-13 04:15:16 +08:00
2016-03-14 09:46:29 +08:00
config . redis . channels . toBBBApps . meeting = 'bigbluebutton:to-bbb-apps:meeting' ;
2016-01-13 04:15:16 +08:00
2016-03-14 09:46:29 +08:00
config . redis . channels . toBBBApps . presentation = 'bigbluebutton:to-bbb-apps:presentation' ;
2016-01-13 04:15:16 +08:00
2016-03-14 09:46:29 +08:00
config . redis . channels . toBBBApps . users = 'bigbluebutton:to-bbb-apps:users' ;
2016-01-13 04:15:16 +08:00
2016-03-14 09:46:29 +08:00
config . redis . channels . toBBBApps . voice = 'bigbluebutton:to-bbb-apps:voice' ;
2016-01-13 04:15:16 +08:00
2016-03-14 09:46:29 +08:00
config . redis . channels . toBBBApps . whiteboard = 'bigbluebutton:to-bbb-apps:whiteboard' ;
2016-01-13 04:15:16 +08:00
2016-03-14 09:46:29 +08:00
config . redis . channels . toBBBApps . polling = 'bigbluebutton:to-bbb-apps:polling' ;
2016-01-13 04:15:16 +08:00
2016-01-15 13:46:41 +08:00
// Logging
2016-01-13 04:15:16 +08:00
config . log = { } ;
2016-03-14 09:46:29 +08:00
if ( Meteor . isServer ) {
if ( process != null && process . env != null && process . env . NODE _ENV == 'production' ) {
config . log . path = '/var/log/bigbluebutton/bbbnode.log' ;
2016-02-02 02:38:15 +08:00
} else {
2016-03-14 09:46:29 +08:00
config . log . path = ` ${ process . env . PWD } /log/development.log ` ;
2016-01-30 09:33:40 +08:00
}
2016-03-14 09:46:29 +08:00
2016-01-15 13:46:41 +08:00
// Setting up a logger in Meteor.log
winston = Winston ; //Meteor.require 'winston'
2016-01-13 04:15:16 +08:00
file = config . log . path ;
transports = [
new winston . transports . Console ( ) , new winston . transports . File ( {
2016-03-14 09:46:29 +08:00
filename : file ,
} ) ,
2016-01-13 04:15:16 +08:00
] ;
Meteor . log = new winston . Logger ( {
2016-03-14 09:46:29 +08:00
transports : transports ,
2016-01-13 04:15:16 +08:00
} ) ;
}
Meteor . config = config ;