|
@@ -223,7 +223,8 @@ function initCommands() {
|
223
|
223
|
},
|
224
|
224
|
|
225
|
225
|
/**
|
226
|
|
- * Starts a file recording or streaming depending on the passed on params.
|
|
226
|
+ * Starts a file recording or streaming session depending on the passed on params.
|
|
227
|
+ * For RTMP streams, `rtmpStreamKey` must be passed on. `rtmpBroadcastID` is optional.
|
227
|
228
|
* For youtube streams, `youtubeStreamKey` must be passed on. `youtubeBroadcastID` is optional.
|
228
|
229
|
* For dropbox recording, recording `mode` should be `file` and a dropbox oauth2 token must be provided.
|
229
|
230
|
* For file recording, recording `mode` should be `file` and optionally `shouldShare` could be passed on.
|
|
@@ -231,13 +232,23 @@ function initCommands() {
|
231
|
232
|
*
|
232
|
233
|
* @param { string } arg.mode - Recording mode, either `file` or `stream`.
|
233
|
234
|
* @param { string } arg.dropboxToken - Dropbox oauth2 token.
|
|
235
|
+ * @param { string } arg.rtmpStreamKey - The RTMP stream key.
|
|
236
|
+ * @param { string } arg.rtmpBroadcastID - The RTMP braodcast ID.
|
234
|
237
|
* @param { boolean } arg.shouldShare - Whether the recording should be shared with the participants or not.
|
235
|
238
|
* Only applies to certain jitsi meet deploys.
|
236
|
239
|
* @param { string } arg.youtubeStreamKey - The youtube stream key.
|
237
|
240
|
* @param { string } arg.youtubeBroadcastID - The youtube broacast ID.
|
238
|
241
|
* @returns {void}
|
239
|
242
|
*/
|
240
|
|
- 'start-recording': ({ mode, dropboxToken, shouldShare, youtubeStreamKey, youtubeBroadcastID }) => {
|
|
243
|
+ 'start-recording': ({
|
|
244
|
+ mode,
|
|
245
|
+ dropboxToken,
|
|
246
|
+ shouldShare,
|
|
247
|
+ rtmpStreamKey,
|
|
248
|
+ rtmpBroadcastID,
|
|
249
|
+ youtubeStreamKey,
|
|
250
|
+ youtubeBroadcastID
|
|
251
|
+ }) => {
|
241
|
252
|
const state = APP.store.getState();
|
242
|
253
|
const conference = getCurrentConference(state);
|
243
|
254
|
|
|
@@ -253,8 +264,8 @@ function initCommands() {
|
253
|
264
|
return;
|
254
|
265
|
}
|
255
|
266
|
|
256
|
|
- if (mode === JitsiRecordingConstants.mode.STREAM && !youtubeStreamKey) {
|
257
|
|
- logger.error('Failed starting recording: missing youtube stream key');
|
|
267
|
+ if (mode === JitsiRecordingConstants.mode.STREAM && !(youtubeStreamKey || rtmpStreamKey)) {
|
|
268
|
+ logger.error('Failed starting recording: missing youtube or RTMP stream key');
|
258
|
269
|
|
259
|
270
|
return;
|
260
|
271
|
}
|
|
@@ -286,9 +297,9 @@ function initCommands() {
|
286
|
297
|
}
|
287
|
298
|
} else if (mode === JitsiRecordingConstants.mode.STREAM) {
|
288
|
299
|
recordingConfig = {
|
289
|
|
- broadcastId: youtubeBroadcastID,
|
|
300
|
+ broadcastId: youtubeBroadcastID || rtmpBroadcastID,
|
290
|
301
|
mode: JitsiRecordingConstants.mode.STREAM,
|
291
|
|
- streamId: youtubeStreamKey
|
|
302
|
+ streamId: youtubeStreamKey || rtmpStreamKey
|
292
|
303
|
};
|
293
|
304
|
} else {
|
294
|
305
|
logger.error('Invalid recording mode provided');
|