containers
containers copied to clipboard
[bitnami/moodle] Always set `$CFG->wwwroot` to HTTPS if `MOODLE_SSLPROXY` set
Description of the change
When $CFG->sslproxy is set (set by MOODLE_SSLPROXY, although see #6534) , $CFG->wwwroot is required to start with https, otherwise Moodle refuses to serve any content except an error message. Previously, the logic generated by the moodle_configure_wwwroot function in libmoodle.sh used to determine the scheme of $CFG->wwwroot dynamically at run time based on the request.
This pull request enhances the behavior of moodle_configure_wwwroot to disable this logic when the MOODLE_SSLPROXY environment variable is set. In such case, $CFG->wwwroot is set statically to HTTPS.
Benefits
/bitnami/moodle/config.php does not need to be fixed manually after creating a new container.
Applicable issues
- fixes #6535
Additional information
Tested on bitnami/moodle:4.0.4-debian-11-r2.