Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[NEW] Ability to configure Jitsi room options via new setting URL Suffix #17950

Merged
merged 3 commits into from
Jun 19, 2020
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion app/livechat/server/api/v1/videoCall.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ API.v1.addRoute('livechat/video.call/:token', {
rid,
domain: rcSettings.get('Jitsi_Domain'),
provider: 'jitsi',
room: rcSettings.get('Jitsi_URL_Room_Prefix') + rcSettings.get('uniqueID') + rid,
room: rcSettings.get('Jitsi_URL_Room_Prefix') + rcSettings.get('uniqueID') + rid + rcSettings.get('Jitsi_URL_Room_Suffix'),
timeout: new Date(Date.now() + 3600 * 1000),
};

Expand Down
2 changes: 1 addition & 1 deletion app/livechat/server/methods/startVideoCall.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ Meteor.methods({
return {
roomId: room._id,
domain: settings.get('Jitsi_Domain'),
jitsiRoom: settings.get('Jitsi_URL_Room_Prefix') + settings.get('uniqueID') + roomId,
jitsiRoom: settings.get('Jitsi_URL_Room_Prefix') + settings.get('uniqueID') + roomId + settings.get('Jitsi_URL_Room_Suffix'),
};
},
});
2 changes: 1 addition & 1 deletion app/videobridge/client/views/videoFlexTab.js
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ Template.videoFlexTab.onRendered(function() {
}

const domain = settings.get('Jitsi_Domain');
const jitsiRoom = settings.get('Jitsi_URL_Room_Prefix') + settings.get('uniqueID') + rid;
const jitsiRoom = settings.get('Jitsi_URL_Room_Prefix') + settings.get('uniqueID') + rid + settings.get('Jitsi_URL_Room_Suffix');
const noSsl = !settings.get('Jitsi_SSL');
const isEnabledTokenAuth = settings.get('Jitsi_Enabled_TokenAuth');

Expand Down
2 changes: 1 addition & 1 deletion app/videobridge/server/methods/jitsiGenerateToken.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Meteor.methods({
throw new Meteor.Error('error-not-allowed', 'not allowed', { method: 'jitsi:generateToken' });
}

const jitsiRoom = settings.get('Jitsi_URL_Room_Prefix') + settings.get('uniqueID') + rid;
const jitsiRoom = settings.get('Jitsi_URL_Room_Prefix') + settings.get('uniqueID') + rid + settings.get('Jitsi_URL_Room_Suffix');

const jitsiDomain = settings.get('Jitsi_Domain');
const jitsiApplicationId = settings.get('Jitsi_Application_ID');
Expand Down
9 changes: 9 additions & 0 deletions app/videobridge/server/settings.js
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,15 @@ Meteor.startup(function() {
public: true,
});

this.add('Jitsi_URL_Room_Suffix', '', {
type: 'string',
enableQuery: {
_id: 'Jitsi_Enabled',
value: true,
},
fthiery marked this conversation as resolved.
Show resolved Hide resolved
public: true,
});

this.add('Jitsi_SSL', true, {
type: 'boolean',
enableQuery: {
Expand Down
5 changes: 3 additions & 2 deletions packages/rocketchat-i18n/i18n/en.i18n.json
Original file line number Diff line number Diff line change
Expand Up @@ -3559,7 +3559,8 @@
"Uploading_file": "Uploading file...",
"Uptime": "Uptime",
"URL": "URL",
"URL_room_prefix": "URL Room Prefix",
"URL_room_prefix": "URL room prefix",
"URL_room_suffix": "URL room suffix",
"Use_Server_configuration": "Use server configuration",
"Use_Room_configuration": "Overwrites the server configuration and use room config",
"Use_account_preference": "Use account preference",
Expand Down Expand Up @@ -3856,4 +3857,4 @@
"Your_server_link": "Your server link",
"Your_temporary_password_is_password": "Your temporary password is <strong>[password]</strong>.",
"Your_workspace_is_ready": "Your workspace is ready to use 🎉"
}
}
5 changes: 3 additions & 2 deletions packages/rocketchat-i18n/i18n/fr.i18n.json
Original file line number Diff line number Diff line change
Expand Up @@ -2845,7 +2845,8 @@
"Uploading_file": "Envoi du fichier en cours...",
"Uptime": "Durée de fonctionnement",
"URL": "URL",
"URL_room_prefix": "URL Préfixe de salon",
"URL_room_prefix": "Préfixe d'URL de salon",
"URL_room_suffix": "Suffixe d'URL de salon",
"Use_account_preference": "Préférence du compte utilisateur",
"Use_Emojis": "Utiliser les émoticônes",
"Use_Global_Settings": "Utiliser les paramètres globaux",
Expand Down Expand Up @@ -3096,4 +3097,4 @@
"Your_question": "Votre question",
"Your_server_link": "Le lien de votre serveur",
"Your_workspace_is_ready": "Votre espace de travail est prêt à l'emploi 🎉"
}
}