totara / totara-docker-dev

A docker setup to create a development environment for Totara Learn
MIT License
49 stars 32 forks source link

Fix config.php array error #300

Closed markmetcalfe closed 1 week ago

markmetcalfe commented 1 week ago

Was getting the following error with the example config.php syntax in PHP 8.3 - I thought I had tested it but I think mutagen wasn't syncing properly, so I was testing against an older config.php without realising

Warning: Undefined array key "HTTP_X_FORWARDED_HOST" in /var/www/totara/src/integration/config.php on line 143
Warning: Undefined array key "HTTP_X_ORIGINAL_HOST" in /var/www/totara/src/integration/config.php on line 144

Couldn't get the foreach loop to make sense with the ?: notation, so I've just set it back to using if statements. I've verified that this setup works with PHP 5.3 and 8.3, and that ngrok still works.