Skip to content

Commit

Permalink
Merge pull request #9 from dennisinteractive/CMS-1659-reverse-proxy
Browse files Browse the repository at this point in the history
Cms 1659 reverse proxy
  • Loading branch information
tashaharrison authored Feb 17, 2021
2 parents 5a27a7d + 87aa904 commit bd4e332
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions scripts/composer/ScriptHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,18 @@ public static function createRequiredFiles(Event $event) {
'required' => TRUE,
],
];

drupal_rewrite_settings($settings, $drupalRoot . '/sites/default/settings.php');

$contents = file_get_contents($drupalRoot . '/sites/default/settings.php');
$settings = <<<EOF
/**
* Reverse Proxy Configuration.
*/
\$settings['reverse_proxy'] = TRUE;
\$settings['reverse_proxy_addresses'] = array(\$_SERVER['REMOTE_ADDR']);
/**
* Environment DB configuration.
*/
Expand Down

0 comments on commit bd4e332

Please sign in to comment.