Advertisement
Guest User

def_config

a guest
Jan 9th, 2018
121
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. const config = {};
  2.  
  3. /** *******************************************************
  4.  COMMON CONFIGURATION
  5.  It's used by Nuve, ErizoController, ErizoAgent and ErizoJS
  6. ********************************************************* */
  7. config.rabbit = {};
  8. config.rabbit.host = 'localhost'; // default value: 'localhost'
  9. config.rabbit.port = 5672; // default value: 5672
  10. // Sets the AQMP heartbeat timeout to detect dead TCP Connections
  11. config.rabbit.heartbeat = 8; // default value: 8 seconds, 0 to disable
  12. config.logger = {};
  13. config.logger.configFile = '../log4js_configuration.json'; // default value: "../log4js_configuration.json"
  14.  
  15. /** *******************************************************
  16.  CLOUD PROVIDER CONFIGURATION
  17.  It's used by Nuve and ErizoController
  18. ********************************************************* */
  19. config.cloudProvider = {};
  20. config.cloudProvider.name = '';
  21.  
  22. /** *******************************************************
  23.  NUVE CONFIGURATION
  24. ********************************************************* */
  25. config.nuve = {};
  26. config.nuve.dataBaseURL = 'localhost/nuvedb'; // default value: 'localhost/nuvedb'
  27. config.nuve.superserviceID = '5796056d9885a03935568ed6'; // default value: ''
  28. config.nuve.superserviceKey = '27616'; // default value: ''
  29. config.nuve.testErizoController = 'localhost:8080'; // default value: 'localhost:8080'
  30. // Nuve Cloud Handler policies are in nuve/nuveAPI/ch_policies/ folder
  31. config.nuve.cloudHandlerPolicy = 'default_policy.js'; // default value: 'default_policy.js'
  32.  
  33.  
  34. /** *******************************************************
  35.  ERIZO CONTROLLER CONFIGURATION
  36. ********************************************************* */
  37. config.erizoController = {};
  38.  
  39. // Use undefined to run clients without Ice Servers
  40. //
  41. // Stun servers format
  42. // {
  43. //     "url": url
  44. // }
  45. //
  46. // Turn servers format
  47. // {
  48. //     "username": username,
  49. //     "credential": password,
  50. //     "url": url
  51. // }
  52. config.erizoController.iceServers = [{ url: 'stun:stun.l.google.com:19302' }]; // default value: [{'url': 'stun:stun.l.google.com:19302'}]
  53.  
  54. // Default and max video bandwidth parameters to be used by clients
  55. config.erizoController.defaultVideoBW = 3000; // default value: 300
  56. config.erizoController.maxVideoBW = 3000; // default value: 300
  57.  
  58. // Public erizoController IP for websockets (useful when behind NATs)
  59. // Use '' to automatically get IP from the interface
  60. config.erizoController.publicIP = ''; // default value: ''
  61. config.erizoController.networkinterface = ''; // default value: ''
  62.  
  63. // This configuration is used by the clients to reach erizoController
  64. // Use '' to use the public IP address instead of a hostname
  65. config.erizoController.hostname = ''; // default value: ''
  66. config.erizoController.port = 8080; // default value: 8080
  67. // Use true if clients communicate with erizoController over SSL
  68. config.erizoController.ssl = false; // default value: false
  69.  
  70. // This configuration is used by erizoController server to listen for connections
  71. // Use true if erizoController listens in HTTPS.
  72. config.erizoController.listen_ssl = false; // default value: false
  73. config.erizoController.listen_port = 8080; // default value: 8080
  74.  
  75. // Custom location for SSL certificates. Default located in /cert
  76. // config.erizoController.ssl_key = '/full/path/to/ssl.key';
  77. // config.erizoController.ssl_cert = '/full/path/to/ssl.crt';
  78. // config.erizoController.sslCaCerts = ['/full/path/to/ca_cert1.crt', '/full/path/to/ca_cert2.crt'];
  79.  
  80. // Use the name of the inferface you want to bind to for websockets
  81. // config.erizoController.networkInterface = 'eth1' // default value: undefined
  82.  
  83. config.erizoController.exitOnNuveCheckFail = false;  // default value: false
  84.  
  85. config.erizoController.warning_n_rooms = 15; // default value: 15
  86. config.erizoController.limit_n_rooms = 20; // default value: 20
  87. config.erizoController.interval_time_keepAlive = 1000; // default value: 1000
  88.  
  89. // Roles to be used by services
  90. config.erizoController.roles =
  91. { presenter: { publish: true, subscribe: true, record: true, stats: true, controlhandlers: true },
  92.   viewer: { subscribe: true },
  93.   viewerWithData: { subscribe: true, publish: { audio: false, video: false, screen: false, data: true } } }; // default value: {"presenter":{"publish": true, "subscribe":true, "record":true}, "viewer":{"subscribe":true}, "viewerWithData":{"subscribe":true, "publish":{"audio":false,"video":false,"screen":false,"data":true}}}
  94.  
  95. // If true, erizoController sends report to rabbitMQ queue "report_handler"
  96. config.erizoController.report = {
  97.   session_events: false,        // Session level events -- default value: false
  98.   connection_events: false,     // Connection (ICE) level events -- default value: false
  99.   rtcp_stats: false,                // RTCP stats -- default value: false
  100. };
  101.  
  102. // Subscriptions to rtcp_stats via AMQP
  103. config.erizoController.reportSubscriptions = {
  104.   maxSubscriptions: 10, // per ErizoJS -- set 0 to disable subscriptions -- default 10
  105.   minInterval: 1,       // in seconds -- default 1
  106.   maxTimeout: 60,           // in seconds -- default 60
  107. };
  108.  
  109. // If undefined, the path will be /tmp/
  110. config.erizoController.recording_path = undefined; // default value: undefined
  111.  
  112. // Erizo Controller Cloud Handler policies are in erizo_controller/erizoController/ch_policies/ folder
  113. config.erizoController.cloudHandlerPolicy = 'default_policy.js'; // default value: 'default_policy.js'
  114.  
  115. /** *******************************************************
  116.  ERIZO AGENT CONFIGURATION
  117. ********************************************************* */
  118. config.erizoAgent = {};
  119.  
  120. // Max processes that ErizoAgent can run
  121. config.erizoAgent.maxProcesses    = 1; // default value: 1
  122. // Number of precesses that ErizoAgent runs when it starts. Always lower than or equals to maxProcesses.
  123. config.erizoAgent.prerunProcesses = 1; // default value: 1
  124.  
  125. // Public erizoAgent IP for ICE candidates (useful when behind NATs)
  126. // Use '' to automatically get IP from the interface
  127. config.erizoAgent.publicIP = ''; // default value: ''
  128. config.erizoAgent.networkinterface = ''; // default value: ''
  129.  
  130. // Use the name of the inferface you want to bind for ICE candidates
  131. // config.erizoAgent.networkInterface = 'eth1' // default value: undefined
  132.  
  133. // Use individual log files for each of the started erizoJS processes
  134. // This files will be named erizo-ERIZO_ID_HASH.log
  135. config.erizoAgent.useIndividualLogFiles = false;
  136.  
  137. // If true this Agent will launch Debug versions of ErizoJS
  138. config.erizoAgent.launchDebugErizoJS = false;
  139.  
  140. // Custom log directory for agent instance log files.
  141. // If useIndividualLogFiles is enabled, files will go here
  142. // Default is [licode_path]/erizo_controller/erizoAgent
  143. // config.erizoAgent.instanceLogDir = '/path/to/dir';
  144.  
  145.  
  146. /** *******************************************************
  147.  ERIZO JS CONFIGURATION
  148. ********************************************************* */
  149. config.erizo = {};
  150.  
  151. // Erizo Logs are piped through erizoAgent by default
  152. // you can control log levels in [licode_path]/erizo_controller/erizoAgent/log4cxx.properties
  153.  
  154. // Number of workers that will be used to handle WebRtcConnections
  155. config.erizo.numWorkers = 24;
  156.  
  157. // Number of workers what will be used for IO (including ICE logic)
  158. config.erizo.numIOWorkers = 1;
  159.  
  160. // STUN server IP address and port to be used by the server.
  161. // if '' is used, the address is discovered locally
  162. // Please note this is only needed if your server does not have a public IP
  163. config.erizo.stunserver = ''; // default value: ''
  164. config.erizo.stunport = 0; // default value: 0
  165.  
  166. // TURN server IP address and port to be used by the server.
  167. // Please note this is not needed in most cases, setting TURN in erizoController for the clients
  168. // is the recommended configuration
  169. // if '' is used, no relay for the server is used
  170. config.erizo.turnserver = ''; // default value: ''
  171. config.erizo.turnport = 0; // default value: 0
  172. config.erizo.turnusername = '';
  173. config.erizo.turnpass = '';
  174. config.erizo.networkinterface = ''; // default value: ''
  175.  
  176. // note, this won't work with all versions of libnice. With 0 all the available ports are used
  177. config.erizo.minport = 0; // default value: 0
  178. config.erizo.maxport = 0; // default value: 0
  179.  
  180. // Use of internal nICEr library instead of libNice.
  181. config.erizo.useNicer = true;  // default value: false
  182.  
  183. config.erizo.disabledHandlers = []; // there are no handlers disabled by default
  184.  
  185. /** *** END **** */
  186. // Following lines are always needed.
  187. var module = module || {};
  188. module.exports = config;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement