Problem/Motivation

One step of my reinstall script is to copy sites/example.settings.local.php and include it in settings.php, (in order to disable render cache and CSS/JS aggregation, among others)
See https://gist.github.com/timplunkett/0fcd916aeb51a8cd5c60 for an example.

Because I personally don't use localhost, or *.local, I now hit the new exception from https://www.drupal.org/node/2410395

Additionally, that issue included a $localCamelCase variable. Fixing that.

Proposed resolution

The commented out example in settings.php is enough, leave example.settings.local.php for actual useful overrides.

Remaining tasks

User interface changes

API changes

CommentFileSizeAuthor
#1 2416563-http_host-1.patch2.22 KBtim.plunkett

Comments

tim.plunkett’s picture

Status: Active » Needs review
StatusFileSize
new2.22 KB
mpdonadio’s picture

Status: Needs review » Reviewed & tested by the community
damien tournoud’s picture

-/**
- * Trust localhost.
- *
- * This will configure several common hostnames used for local development to
- * be trusted hosts.
- */
-$settings['trusted_host_patterns'] = array(
-  '^localhost$',
-  '^localhost\.*',
-  '\.local$',
-);

Maybe just comment it out instead of completely removing it?

tim.plunkett’s picture

We have a commented out version in default.settings.php:
http://cgit.drupalcode.org/drupal/tree/sites/default/default.settings.ph...

damien tournoud’s picture

Great, that's fine.

tim.plunkett’s picture

Issue tags: +Quick fix
alexpott’s picture

Status: Reviewed & tested by the community » Fixed

This issue is a normal bug fix, and doesn't include any disruptive changes, so it is allowed per https://www.drupal.org/core/beta-changes. Committed 7394ae9 and pushed to 8.0.x. Thanks!

  • alexpott committed 7394ae9 on 8.0.x
    Issue #2416563 by tim.plunkett: Follow-up to "HTTP_HOST header cannot be...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.