Merge branch 'MDL-73200' of https://github.com/jfederico/moodle
This commit is contained in:
@@ -30,10 +30,10 @@ use mod_bigbluebuttonbn\recording;
|
||||
class config {
|
||||
|
||||
/** @var string Default bigbluebutton server url */
|
||||
public const DEFAULT_SERVER_URL = 'http://test-install.blindsidenetworks.com/bigbluebutton/';
|
||||
public const DEFAULT_SERVER_URL = 'https://test-moodle.blindsidenetworks.com/bigbluebutton/';
|
||||
|
||||
/** @var string Default bigbluebutton server shared secret */
|
||||
public const DEFAULT_SHARED_SECRET = '8cd8ef52e8e101574e400365b55e11a6';
|
||||
public const DEFAULT_SHARED_SECRET = '0b21fcaf34673a8c3ec8ed877d76ae34';
|
||||
|
||||
/**
|
||||
* Returns moodle version.
|
||||
|
||||
@@ -25,6 +25,7 @@
|
||||
*/
|
||||
|
||||
use mod_bigbluebuttonbn\plugin;
|
||||
use mod_bigbluebuttonbn\local\config;
|
||||
|
||||
defined('MOODLE_INTERNAL') || die();
|
||||
|
||||
@@ -420,6 +421,16 @@ function xmldb_bigbluebuttonbn_upgrade($oldversion = 0) {
|
||||
upgrade_mod_savepoint(true, 2021083101, 'bigbluebuttonbn');
|
||||
}
|
||||
|
||||
if ($oldversion < 2021091408) {
|
||||
// Change BigBliueButton Server credentials to new defaults if test-install is being used.
|
||||
if (config::get('server_url') == 'http://test-install.blindsidenetworks.com/bigbluebutton/') {
|
||||
set_config('bigbluebuttonbn_server_url', config::DEFAULT_SERVER_URL);
|
||||
set_config('bigbluebuttonbn_shared_secret', config::DEFAULT_SHARED_SECRET);
|
||||
}
|
||||
// Bigbluebuttonbn savepoint reached.
|
||||
upgrade_mod_savepoint(true, 2021091408, 'bigbluebuttonbn');
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -129,7 +129,7 @@ $string['config_general_description'] = 'These settings are <b>always</b> used';
|
||||
$string['config_server_url'] = 'BigBlueButton Server URL';
|
||||
$string['config_server_url_description'] = 'The URL of your BigBlueButton server must end with /bigbluebutton/. (This default URL is for a BigBlueButton server provided by Blindside Networks that you can use for testing.)';
|
||||
$string['config_shared_secret'] = 'BigBlueButton Shared Secret';
|
||||
$string['config_shared_secret_description'] = 'The security salt of your BigBlueButton server. (This default salt is for a BigBlueButton server provided by Blindside Networks that you can use for testing.)';
|
||||
$string['config_shared_secret_description'] = 'The security secret of your BigBlueButton server. (This default secret is for a BigBlueButton server provided by Blindside Networks that you can use for testing.)';
|
||||
|
||||
$string['config_recording'] = 'Configuration for "Record meeting" feature';
|
||||
$string['config_recording_description'] = 'These settings are feature specific';
|
||||
@@ -315,7 +315,7 @@ $string['index_confirm_end'] = 'Do you wish to end the virtual class?';
|
||||
$string['index_disabled'] = 'disabled';
|
||||
$string['index_enabled'] = 'enabled';
|
||||
$string['index_ending'] = 'Ending the virtual classroom ... please wait';
|
||||
$string['index_error_checksum'] = 'A checksum error occurred. Make sure you entered the correct salt.';
|
||||
$string['index_error_checksum'] = 'A checksum error occurred. Make sure you entered the correct secret.';
|
||||
$string['index_error_forciblyended'] = 'Unable to join this meeting because it has been manually ended.';
|
||||
$string['index_error_unable_display'] = 'Unable to display the meetings. Please check the url of the BigBlueButton server AND check to see if the BigBlueButton server is running.';
|
||||
$string['index_heading_actions'] = 'Actions';
|
||||
|
||||
@@ -96,10 +96,10 @@ XPATH
|
||||
* Send a query to the mock server
|
||||
*
|
||||
* @param string $endpoint
|
||||
* @throws coding_exception
|
||||
* @param array $params
|
||||
*/
|
||||
protected function send_mock_request(string $endpoint): void {
|
||||
$url = $this->get_mocked_server_url($endpoint);
|
||||
protected function send_mock_request(string $endpoint, array $params = []): void {
|
||||
$url = $this->get_mocked_server_url($endpoint, $params);
|
||||
|
||||
$curl = new \curl();
|
||||
$curl->get($url->out_omit_querystring(), $url->params());
|
||||
@@ -173,7 +173,10 @@ XPATH
|
||||
* @Given the BigBlueButtonBN server has sent recording ready notifications
|
||||
*/
|
||||
public function trigger_recording_ready_notification(): void {
|
||||
$this->send_mock_request('backoffice/sendNotifications');
|
||||
$this->send_mock_request('backoffice/sendNotifications', [
|
||||
'secret' => \mod_bigbluebuttonbn\local\config::DEFAULT_SHARED_SECRET,
|
||||
]
|
||||
);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -27,6 +27,6 @@
|
||||
defined('MOODLE_INTERNAL') || die;
|
||||
|
||||
|
||||
$plugin->version = 2021091407;
|
||||
$plugin->version = 2021091408;
|
||||
$plugin->requires = 2020061500;
|
||||
$plugin->component = 'mod_bigbluebuttonbn';
|
||||
|
||||
Reference in New Issue
Block a user