Skip to content

Commit 0ab37f4

Browse files
committed
Disable sqlsrv encryption by default
We don't need it, we don't want it. And, with ODBC 18 it's enabled by default. Allowing it in moodle-docker would require cert validations and other stuff that we don't need for dev/test purposes. Fixes #253
1 parent 4c4d1d5 commit 0ab37f4

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

config.docker-template.php

+8
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,14 @@
1313
$CFG->prefix = 'm_';
1414
$CFG->dboptions = ['dbcollation' => getenv('MOODLE_DOCKER_DBCOLLATION')];
1515

16+
if (getenv('MOODLE_DOCKER_DBTYPE') === 'sqlsrv') {
17+
$CFG->dboptions['extrainfo'] = [
18+
// Disable Encryption for now on sqlsrv.
19+
// It is on by default from msodbcsql18.
20+
'Encrypt' => false,
21+
];
22+
}
23+
1624
$host = 'localhost';
1725
if (!empty(getenv('MOODLE_DOCKER_WEB_HOST'))) {
1826
$host = getenv('MOODLE_DOCKER_WEB_HOST');

0 commit comments

Comments
 (0)