Skip to content

Commit d2d14b1

Browse files
authored
Update settings.d10.php to 10.3.9 and add state cache flag (#149)
* Update settings.d10.php to 10.3.9 and add state cache flag Update the settings.php file that comes with 10.3.9 and add the missing state cache flag to remove warning in Drupal status report. Leave all active setting configurations as-is. * Add back in Temporary file path - removed by accident
1 parent a1d2506 commit d2d14b1

File tree

1 file changed

+62
-32
lines changed

1 file changed

+62
-32
lines changed

charts/drupal/conf/settings.d10.php

Lines changed: 62 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -24,18 +24,18 @@
2424
* 'sites/default' will be used.
2525
*
2626
* For example, for a fictitious site installed at
27-
* https://www.drupal.org:8080/mysite/test/, the 'settings.php' file is searched
27+
* https://www.drupal.org:8080/my-site/test/, the 'settings.php' file is searched
2828
* for in the following directories:
2929
*
30-
* - sites/8080.www.drupal.org.mysite.test
31-
* - sites/www.drupal.org.mysite.test
32-
* - sites/drupal.org.mysite.test
33-
* - sites/org.mysite.test
30+
* - sites/8080.www.drupal.org.my-site.test
31+
* - sites/www.drupal.org.my-site.test
32+
* - sites/drupal.org.my-site.test
33+
* - sites/org.my-site.test
3434
*
35-
* - sites/8080.www.drupal.org.mysite
36-
* - sites/www.drupal.org.mysite
37-
* - sites/drupal.org.mysite
38-
* - sites/org.mysite
35+
* - sites/8080.www.drupal.org.my-site
36+
* - sites/www.drupal.org.my-site
37+
* - sites/drupal.org.my-site
38+
* - sites/org.my-site
3939
*
4040
* - sites/8080.www.drupal.org
4141
* - sites/www.drupal.org
@@ -46,8 +46,8 @@
4646
*
4747
* Note that if you are installing on a non-standard port number, prefix the
4848
* hostname with that number. For example,
49-
* https://www.drupal.org:8080/mysite/test/ could be loaded from
50-
* sites/8080.www.drupal.org.mysite.test/.
49+
* https://www.drupal.org:8080/my-site/test/ could be loaded from
50+
* sites/8080.www.drupal.org.my-site.test/.
5151
*
5252
* @see example.sites.php
5353
* @see \Drupal\Core\DrupalKernel::getSitePath()
@@ -77,9 +77,9 @@
7777
*
7878
* @code
7979
* $databases['default']['default'] = [
80-
* 'database' => 'databasename',
81-
* 'username' => 'sqlusername',
82-
* 'password' => 'sqlpassword',
80+
* 'database' => 'database_name',
81+
* 'username' => 'sql_username',
82+
* 'password' => 'sql_password',
8383
* 'host' => 'localhost',
8484
* 'port' => '3306',
8585
* 'driver' => 'mysql',
@@ -249,8 +249,8 @@
249249
*
250250
* WARNING: The above defaults are designed for database portability. Changing
251251
* them may cause unexpected behavior, including potential data loss. See
252-
* https://www.drupal.org/developing/api/database/configuration for more
253-
* information on these defaults and the potential issues.
252+
* https://www.drupal.org/docs/8/api/database-api/database-configuration for
253+
* more information on these defaults and the potential issues.
254254
*
255255
* More details can be found in the constructor methods for each driver:
256256
* - \Drupal\mysql\Driver\Database\mysql\Connection::__construct()
@@ -261,9 +261,9 @@
261261
* @code
262262
* $databases['default']['default'] = [
263263
* 'driver' => 'pgsql',
264-
* 'database' => 'databasename',
265-
* 'username' => 'sqlusername',
266-
* 'password' => 'sqlpassword',
264+
* 'database' => 'database_name',
265+
* 'username' => 'sql_username',
266+
* 'password' => 'sql_password',
267267
* 'host' => 'localhost',
268268
* 'prefix' => '',
269269
* ];
@@ -273,7 +273,7 @@
273273
* @code
274274
* $databases['default']['default'] = [
275275
* 'driver' => 'sqlite',
276-
* 'database' => '/path/to/databasefilename',
276+
* 'database' => '/path/to/database_filename',
277277
* ];
278278
* @endcode
279279
*
@@ -283,13 +283,34 @@
283283
* 'driver' => 'my_driver',
284284
* 'namespace' => 'Drupal\my_module\Driver\Database\my_driver',
285285
* 'autoload' => 'modules/my_module/src/Driver/Database/my_driver/',
286-
* 'database' => 'databasename',
287-
* 'username' => 'sqlusername',
288-
* 'password' => 'sqlpassword',
286+
* 'database' => 'database_name',
287+
* 'username' => 'sql_username',
288+
* 'password' => 'sql_password',
289289
* 'host' => 'localhost',
290290
* 'prefix' => '',
291291
* ];
292292
* @endcode
293+
*
294+
* Sample Database configuration format for a driver that is extending another
295+
* database driver.
296+
* @code
297+
* $databases['default']['default'] = [
298+
* 'driver' => 'my_driver',
299+
* 'namespace' => 'Drupal\my_module\Driver\Database\my_driver',
300+
* 'autoload' => 'modules/my_module/src/Driver/Database/my_driver/',
301+
* 'database' => 'database_name',
302+
* 'username' => 'sql_username',
303+
* 'password' => 'sql_password',
304+
* 'host' => 'localhost',
305+
* 'prefix' => '',
306+
* 'dependencies' => [
307+
* 'parent_module' => [
308+
* 'namespace' => 'Drupal\parent_module',
309+
* 'autoload' => 'core/modules/parent_module/src/',
310+
* ],
311+
* ],
312+
* ];
313+
* @endcode
293314
*/
294315

295316
/**
@@ -402,14 +423,13 @@
402423
* security, or encryption benefits. In an environment where Drupal
403424
* is behind a reverse proxy, the real IP address of the client should
404425
* be determined such that the correct client IP address is available
405-
* to Drupal's logging, statistics, and access management systems. In
406-
* the most simple scenario, the proxy server will add an
407-
* X-Forwarded-For header to the request that contains the client IP
408-
* address. However, HTTP headers are vulnerable to spoofing, where a
409-
* malicious client could bypass restrictions by setting the
410-
* X-Forwarded-For header directly. Therefore, Drupal's proxy
411-
* configuration requires the IP addresses of all remote proxies to be
412-
* specified in $settings['reverse_proxy_addresses'] to work correctly.
426+
* to Drupal's logging and access management systems. In the most simple
427+
* scenario, the proxy server will add an X-Forwarded-For header to the request
428+
* that contains the client IP address. However, HTTP headers are vulnerable to
429+
* spoofing, where a malicious client could bypass restrictions by setting the
430+
* X-Forwarded-For header directly. Therefore, Drupal's proxy configuration
431+
* requires the IP addresses of all remote proxies to be specified in
432+
* $settings['reverse_proxy_addresses'] to work correctly.
413433
*
414434
* Enable this setting to get Drupal to determine the client IP from the
415435
* X-Forwarded-For header. If you are unsure about this setting, do not have a
@@ -635,7 +655,7 @@
635655
* the output of phpinfo(). The full output can contain sensitive information
636656
* so by default Drupal removes some sections.
637657
*
638-
* This behaviour can be configured by setting this variable to a different
658+
* This behavior can be configured by setting this variable to a different
639659
* value corresponding to the flags parameter of phpinfo().
640660
*
641661
* If you need to expose more information in the report - for example to debug a
@@ -855,6 +875,16 @@
855875
*/
856876
$settings['entity_update_backup'] = TRUE;
857877

878+
/**
879+
* State caching.
880+
*
881+
* State caching uses the cache collector pattern to cache all requested keys
882+
* from the state API in a single cache entry, which can greatly reduce the
883+
* amount of database queries. However, some sites may use state with a
884+
* lot of dynamic keys which could result in a very large cache.
885+
*/
886+
$settings['state_cache'] = TRUE;
887+
858888
/**
859889
* Node migration type.
860890
*

0 commit comments

Comments
 (0)