Skip to content
Snippets Groups Projects
Commit 461acccd authored by Jakob P's avatar Jakob P
Browse files

Revert "Issue #3404644: Read from reverse_proxy_addresses not reverse_proxies"

This reverts commit 959b20da.
parent 959b20da
Branches 2497145-front-page
No related tags found
No related merge requests found
......@@ -98,16 +98,12 @@ class PlatformInfo implements PlatformInfoInterface {
*/
public function __construct(string $site_path, Settings $settings, StateInterface $state) {
// Generate the Drupal site path from service.
// Generate the Drupal sitepath from service.
$this->sitePath = $site_path;
// Take the IP addresses from the 'reverse_proxy_addresses' setting.
$reverse_proxies = $settings->get('reverse_proxy_addresses');
if ($reverse_proxies === NULL) {
// Fallback to legacy setting.
$reverse_proxies = $settings->get('reverse_proxies');
}
if (is_array($reverse_proxies)) {
// Take the IP addresses from Public LBs and Proxies via the 'reverse_proxies' setting.
// Note: This is different from 'reverse_proxy_addresses' which contains ALL reverse proxies.
if (is_array($reverse_proxies = $settings->get('reverse_proxies'))) {
foreach ($reverse_proxies as $reverse_proxy) {
if ($reverse_proxy && strpos($reverse_proxy, '.')) {
$this->balancerAddresses[] = $reverse_proxy;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment