annotate sites/default/default.settings.php @ 0:c75dbcec494b

Initial commit from drush-created site
author Chris Cannam
date Thu, 05 Jul 2018 14:24:15 +0000
parents
children
rev   line source
Chris@0 1 <?php
Chris@0 2
Chris@0 3 // @codingStandardsIgnoreFile
Chris@0 4
Chris@0 5 /**
Chris@0 6 * @file
Chris@0 7 * Drupal site-specific configuration file.
Chris@0 8 *
Chris@0 9 * IMPORTANT NOTE:
Chris@0 10 * This file may have been set to read-only by the Drupal installation program.
Chris@0 11 * If you make changes to this file, be sure to protect it again after making
Chris@0 12 * your modifications. Failure to remove write permissions to this file is a
Chris@0 13 * security risk.
Chris@0 14 *
Chris@0 15 * In order to use the selection rules below the multisite aliasing file named
Chris@0 16 * sites/sites.php must be present. Its optional settings will be loaded, and
Chris@0 17 * the aliases in the array $sites will override the default directory rules
Chris@0 18 * below. See sites/example.sites.php for more information about aliases.
Chris@0 19 *
Chris@0 20 * The configuration directory will be discovered by stripping the website's
Chris@0 21 * hostname from left to right and pathname from right to left. The first
Chris@0 22 * configuration file found will be used and any others will be ignored. If no
Chris@0 23 * other configuration file is found then the default configuration file at
Chris@0 24 * 'sites/default' will be used.
Chris@0 25 *
Chris@0 26 * For example, for a fictitious site installed at
Chris@0 27 * https://www.drupal.org:8080/mysite/test/, the 'settings.php' file is searched
Chris@0 28 * for in the following directories:
Chris@0 29 *
Chris@0 30 * - sites/8080.www.drupal.org.mysite.test
Chris@0 31 * - sites/www.drupal.org.mysite.test
Chris@0 32 * - sites/drupal.org.mysite.test
Chris@0 33 * - sites/org.mysite.test
Chris@0 34 *
Chris@0 35 * - sites/8080.www.drupal.org.mysite
Chris@0 36 * - sites/www.drupal.org.mysite
Chris@0 37 * - sites/drupal.org.mysite
Chris@0 38 * - sites/org.mysite
Chris@0 39 *
Chris@0 40 * - sites/8080.www.drupal.org
Chris@0 41 * - sites/www.drupal.org
Chris@0 42 * - sites/drupal.org
Chris@0 43 * - sites/org
Chris@0 44 *
Chris@0 45 * - sites/default
Chris@0 46 *
Chris@0 47 * Note that if you are installing on a non-standard port number, prefix the
Chris@0 48 * hostname with that number. For example,
Chris@0 49 * https://www.drupal.org:8080/mysite/test/ could be loaded from
Chris@0 50 * sites/8080.www.drupal.org.mysite.test/.
Chris@0 51 *
Chris@0 52 * @see example.sites.php
Chris@0 53 * @see \Drupal\Core\DrupalKernel::getSitePath()
Chris@0 54 *
Chris@0 55 * In addition to customizing application settings through variables in
Chris@0 56 * settings.php, you can create a services.yml file in the same directory to
Chris@0 57 * register custom, site-specific service definitions and/or swap out default
Chris@0 58 * implementations with custom ones.
Chris@0 59 */
Chris@0 60
Chris@0 61 /**
Chris@0 62 * Database settings:
Chris@0 63 *
Chris@0 64 * The $databases array specifies the database connection or
Chris@0 65 * connections that Drupal may use. Drupal is able to connect
Chris@0 66 * to multiple databases, including multiple types of databases,
Chris@0 67 * during the same request.
Chris@0 68 *
Chris@0 69 * One example of the simplest connection array is shown below. To use the
Chris@0 70 * sample settings, copy and uncomment the code below between the @code and
Chris@0 71 * @endcode lines and paste it after the $databases declaration. You will need
Chris@0 72 * to replace the database username and password and possibly the host and port
Chris@0 73 * with the appropriate credentials for your database system.
Chris@0 74 *
Chris@0 75 * The next section describes how to customize the $databases array for more
Chris@0 76 * specific needs.
Chris@0 77 *
Chris@0 78 * @code
Chris@0 79 * $databases['default']['default'] = array (
Chris@0 80 * 'database' => 'databasename',
Chris@0 81 * 'username' => 'sqlusername',
Chris@0 82 * 'password' => 'sqlpassword',
Chris@0 83 * 'host' => 'localhost',
Chris@0 84 * 'port' => '3306',
Chris@0 85 * 'driver' => 'mysql',
Chris@0 86 * 'prefix' => '',
Chris@0 87 * 'collation' => 'utf8mb4_general_ci',
Chris@0 88 * );
Chris@0 89 * @endcode
Chris@0 90 */
Chris@0 91 $databases = array();
Chris@0 92
Chris@0 93 /**
Chris@0 94 * Customizing database settings.
Chris@0 95 *
Chris@0 96 * Many of the values of the $databases array can be customized for your
Chris@0 97 * particular database system. Refer to the sample in the section above as a
Chris@0 98 * starting point.
Chris@0 99 *
Chris@0 100 * The "driver" property indicates what Drupal database driver the
Chris@0 101 * connection should use. This is usually the same as the name of the
Chris@0 102 * database type, such as mysql or sqlite, but not always. The other
Chris@0 103 * properties will vary depending on the driver. For SQLite, you must
Chris@0 104 * specify a database file name in a directory that is writable by the
Chris@0 105 * webserver. For most other drivers, you must specify a
Chris@0 106 * username, password, host, and database name.
Chris@0 107 *
Chris@0 108 * Transaction support is enabled by default for all drivers that support it,
Chris@0 109 * including MySQL. To explicitly disable it, set the 'transactions' key to
Chris@0 110 * FALSE.
Chris@0 111 * Note that some configurations of MySQL, such as the MyISAM engine, don't
Chris@0 112 * support it and will proceed silently even if enabled. If you experience
Chris@0 113 * transaction related crashes with such configuration, set the 'transactions'
Chris@0 114 * key to FALSE.
Chris@0 115 *
Chris@0 116 * For each database, you may optionally specify multiple "target" databases.
Chris@0 117 * A target database allows Drupal to try to send certain queries to a
Chris@0 118 * different database if it can but fall back to the default connection if not.
Chris@0 119 * That is useful for primary/replica replication, as Drupal may try to connect
Chris@0 120 * to a replica server when appropriate and if one is not available will simply
Chris@0 121 * fall back to the single primary server (The terms primary/replica are
Chris@0 122 * traditionally referred to as master/slave in database server documentation).
Chris@0 123 *
Chris@0 124 * The general format for the $databases array is as follows:
Chris@0 125 * @code
Chris@0 126 * $databases['default']['default'] = $info_array;
Chris@0 127 * $databases['default']['replica'][] = $info_array;
Chris@0 128 * $databases['default']['replica'][] = $info_array;
Chris@0 129 * $databases['extra']['default'] = $info_array;
Chris@0 130 * @endcode
Chris@0 131 *
Chris@0 132 * In the above example, $info_array is an array of settings described above.
Chris@0 133 * The first line sets a "default" database that has one primary database
Chris@0 134 * (the second level default). The second and third lines create an array
Chris@0 135 * of potential replica databases. Drupal will select one at random for a given
Chris@0 136 * request as needed. The fourth line creates a new database with a name of
Chris@0 137 * "extra".
Chris@0 138 *
Chris@0 139 * You can optionally set prefixes for some or all database table names
Chris@0 140 * by using the 'prefix' setting. If a prefix is specified, the table
Chris@0 141 * name will be prepended with its value. Be sure to use valid database
Chris@0 142 * characters only, usually alphanumeric and underscore. If no prefixes
Chris@0 143 * are desired, leave it as an empty string ''.
Chris@0 144 *
Chris@0 145 * To have all database names prefixed, set 'prefix' as a string:
Chris@0 146 * @code
Chris@0 147 * 'prefix' => 'main_',
Chris@0 148 * @endcode
Chris@0 149 *
Chris@0 150 * Per-table prefixes are deprecated as of Drupal 8.2, and will be removed in
Chris@0 151 * Drupal 9.0. After that, only a single prefix for all tables will be
Chris@0 152 * supported.
Chris@0 153 *
Chris@0 154 * To provide prefixes for specific tables, set 'prefix' as an array.
Chris@0 155 * The array's keys are the table names and the values are the prefixes.
Chris@0 156 * The 'default' element is mandatory and holds the prefix for any tables
Chris@0 157 * not specified elsewhere in the array. Example:
Chris@0 158 * @code
Chris@0 159 * 'prefix' => array(
Chris@0 160 * 'default' => 'main_',
Chris@0 161 * 'users' => 'shared_',
Chris@0 162 * 'sessions' => 'shared_',
Chris@0 163 * 'role' => 'shared_',
Chris@0 164 * 'authmap' => 'shared_',
Chris@0 165 * ),
Chris@0 166 * @endcode
Chris@0 167 * You can also use a reference to a schema/database as a prefix. This may be
Chris@0 168 * useful if your Drupal installation exists in a schema that is not the default
Chris@0 169 * or you want to access several databases from the same code base at the same
Chris@0 170 * time.
Chris@0 171 * Example:
Chris@0 172 * @code
Chris@0 173 * 'prefix' => array(
Chris@0 174 * 'default' => 'main.',
Chris@0 175 * 'users' => 'shared.',
Chris@0 176 * 'sessions' => 'shared.',
Chris@0 177 * 'role' => 'shared.',
Chris@0 178 * 'authmap' => 'shared.',
Chris@0 179 * );
Chris@0 180 * @endcode
Chris@0 181 * NOTE: MySQL and SQLite's definition of a schema is a database.
Chris@0 182 *
Chris@0 183 * Advanced users can add or override initial commands to execute when
Chris@0 184 * connecting to the database server, as well as PDO connection settings. For
Chris@0 185 * example, to enable MySQL SELECT queries to exceed the max_join_size system
Chris@0 186 * variable, and to reduce the database connection timeout to 5 seconds:
Chris@0 187 * @code
Chris@0 188 * $databases['default']['default'] = array(
Chris@0 189 * 'init_commands' => array(
Chris@0 190 * 'big_selects' => 'SET SQL_BIG_SELECTS=1',
Chris@0 191 * ),
Chris@0 192 * 'pdo' => array(
Chris@0 193 * PDO::ATTR_TIMEOUT => 5,
Chris@0 194 * ),
Chris@0 195 * );
Chris@0 196 * @endcode
Chris@0 197 *
Chris@0 198 * WARNING: The above defaults are designed for database portability. Changing
Chris@0 199 * them may cause unexpected behavior, including potential data loss. See
Chris@0 200 * https://www.drupal.org/developing/api/database/configuration for more
Chris@0 201 * information on these defaults and the potential issues.
Chris@0 202 *
Chris@0 203 * More details can be found in the constructor methods for each driver:
Chris@0 204 * - \Drupal\Core\Database\Driver\mysql\Connection::__construct()
Chris@0 205 * - \Drupal\Core\Database\Driver\pgsql\Connection::__construct()
Chris@0 206 * - \Drupal\Core\Database\Driver\sqlite\Connection::__construct()
Chris@0 207 *
Chris@0 208 * Sample Database configuration format for PostgreSQL (pgsql):
Chris@0 209 * @code
Chris@0 210 * $databases['default']['default'] = array(
Chris@0 211 * 'driver' => 'pgsql',
Chris@0 212 * 'database' => 'databasename',
Chris@0 213 * 'username' => 'sqlusername',
Chris@0 214 * 'password' => 'sqlpassword',
Chris@0 215 * 'host' => 'localhost',
Chris@0 216 * 'prefix' => '',
Chris@0 217 * );
Chris@0 218 * @endcode
Chris@0 219 *
Chris@0 220 * Sample Database configuration format for SQLite (sqlite):
Chris@0 221 * @code
Chris@0 222 * $databases['default']['default'] = array(
Chris@0 223 * 'driver' => 'sqlite',
Chris@0 224 * 'database' => '/path/to/databasefilename',
Chris@0 225 * );
Chris@0 226 * @endcode
Chris@0 227 */
Chris@0 228
Chris@0 229 /**
Chris@0 230 * Location of the site configuration files.
Chris@0 231 *
Chris@0 232 * The $config_directories array specifies the location of file system
Chris@0 233 * directories used for configuration data. On install, the "sync" directory is
Chris@0 234 * created. This is used for configuration imports. The "active" directory is
Chris@0 235 * not created by default since the default storage for active configuration is
Chris@0 236 * the database rather than the file system. (This can be changed. See "Active
Chris@0 237 * configuration settings" below).
Chris@0 238 *
Chris@0 239 * The default location for the "sync" directory is inside a randomly-named
Chris@0 240 * directory in the public files path. The setting below allows you to override
Chris@0 241 * the "sync" location.
Chris@0 242 *
Chris@0 243 * If you use files for the "active" configuration, you can tell the
Chris@0 244 * Configuration system where this directory is located by adding an entry with
Chris@0 245 * array key CONFIG_ACTIVE_DIRECTORY.
Chris@0 246 *
Chris@0 247 * Example:
Chris@0 248 * @code
Chris@0 249 * $config_directories = array(
Chris@0 250 * CONFIG_SYNC_DIRECTORY => '/directory/outside/webroot',
Chris@0 251 * );
Chris@0 252 * @endcode
Chris@0 253 */
Chris@0 254 $config_directories = array();
Chris@0 255
Chris@0 256 /**
Chris@0 257 * Settings:
Chris@0 258 *
Chris@0 259 * $settings contains environment-specific configuration, such as the files
Chris@0 260 * directory and reverse proxy address, and temporary configuration, such as
Chris@0 261 * security overrides.
Chris@0 262 *
Chris@0 263 * @see \Drupal\Core\Site\Settings::get()
Chris@0 264 */
Chris@0 265
Chris@0 266 /**
Chris@0 267 * The active installation profile.
Chris@0 268 *
Chris@0 269 * Changing this after installation is not recommended as it changes which
Chris@0 270 * directories are scanned during extension discovery. If this is set prior to
Chris@0 271 * installation this value will be rewritten according to the profile selected
Chris@0 272 * by the user.
Chris@0 273 *
Chris@0 274 * @see install_select_profile()
Chris@0 275 *
Chris@0 276 * @deprecated in Drupal 8.3.0 and will be removed before Drupal 9.0.0. The
Chris@0 277 * install profile is written to the core.extension configuration. If a
Chris@0 278 * service requires the install profile use the 'install_profile' container
Chris@0 279 * parameter. Functional code can use \Drupal::installProfile().
Chris@0 280 */
Chris@0 281 # $settings['install_profile'] = '';
Chris@0 282
Chris@0 283 /**
Chris@0 284 * Salt for one-time login links, cancel links, form tokens, etc.
Chris@0 285 *
Chris@0 286 * This variable will be set to a random value by the installer. All one-time
Chris@0 287 * login links will be invalidated if the value is changed. Note that if your
Chris@0 288 * site is deployed on a cluster of web servers, you must ensure that this
Chris@0 289 * variable has the same value on each server.
Chris@0 290 *
Chris@0 291 * For enhanced security, you may set this variable to the contents of a file
Chris@0 292 * outside your document root; you should also ensure that this file is not
Chris@0 293 * stored with backups of your database.
Chris@0 294 *
Chris@0 295 * Example:
Chris@0 296 * @code
Chris@0 297 * $settings['hash_salt'] = file_get_contents('/home/example/salt.txt');
Chris@0 298 * @endcode
Chris@0 299 */
Chris@0 300 $settings['hash_salt'] = '';
Chris@0 301
Chris@0 302 /**
Chris@0 303 * Deployment identifier.
Chris@0 304 *
Chris@0 305 * Drupal's dependency injection container will be automatically invalidated and
Chris@0 306 * rebuilt when the Drupal core version changes. When updating contributed or
Chris@0 307 * custom code that changes the container, changing this identifier will also
Chris@0 308 * allow the container to be invalidated as soon as code is deployed.
Chris@0 309 */
Chris@0 310 # $settings['deployment_identifier'] = \Drupal::VERSION;
Chris@0 311
Chris@0 312 /**
Chris@0 313 * Access control for update.php script.
Chris@0 314 *
Chris@0 315 * If you are updating your Drupal installation using the update.php script but
Chris@0 316 * are not logged in using either an account with the "Administer software
Chris@0 317 * updates" permission or the site maintenance account (the account that was
Chris@0 318 * created during installation), you will need to modify the access check
Chris@0 319 * statement below. Change the FALSE to a TRUE to disable the access check.
Chris@0 320 * After finishing the upgrade, be sure to open this file again and change the
Chris@0 321 * TRUE back to a FALSE!
Chris@0 322 */
Chris@0 323 $settings['update_free_access'] = FALSE;
Chris@0 324
Chris@0 325 /**
Chris@0 326 * External access proxy settings:
Chris@0 327 *
Chris@0 328 * If your site must access the Internet via a web proxy then you can enter the
Chris@0 329 * proxy settings here. Set the full URL of the proxy, including the port, in
Chris@0 330 * variables:
Chris@0 331 * - $settings['http_client_config']['proxy']['http']: The proxy URL for HTTP
Chris@0 332 * requests.
Chris@0 333 * - $settings['http_client_config']['proxy']['https']: The proxy URL for HTTPS
Chris@0 334 * requests.
Chris@0 335 * You can pass in the user name and password for basic authentication in the
Chris@0 336 * URLs in these settings.
Chris@0 337 *
Chris@0 338 * You can also define an array of host names that can be accessed directly,
Chris@0 339 * bypassing the proxy, in $settings['http_client_config']['proxy']['no'].
Chris@0 340 */
Chris@0 341 # $settings['http_client_config']['proxy']['http'] = 'http://proxy_user:proxy_pass@example.com:8080';
Chris@0 342 # $settings['http_client_config']['proxy']['https'] = 'http://proxy_user:proxy_pass@example.com:8080';
Chris@0 343 # $settings['http_client_config']['proxy']['no'] = ['127.0.0.1', 'localhost'];
Chris@0 344
Chris@0 345 /**
Chris@0 346 * Reverse Proxy Configuration:
Chris@0 347 *
Chris@0 348 * Reverse proxy servers are often used to enhance the performance
Chris@0 349 * of heavily visited sites and may also provide other site caching,
Chris@0 350 * security, or encryption benefits. In an environment where Drupal
Chris@0 351 * is behind a reverse proxy, the real IP address of the client should
Chris@0 352 * be determined such that the correct client IP address is available
Chris@0 353 * to Drupal's logging, statistics, and access management systems. In
Chris@0 354 * the most simple scenario, the proxy server will add an
Chris@0 355 * X-Forwarded-For header to the request that contains the client IP
Chris@0 356 * address. However, HTTP headers are vulnerable to spoofing, where a
Chris@0 357 * malicious client could bypass restrictions by setting the
Chris@0 358 * X-Forwarded-For header directly. Therefore, Drupal's proxy
Chris@0 359 * configuration requires the IP addresses of all remote proxies to be
Chris@0 360 * specified in $settings['reverse_proxy_addresses'] to work correctly.
Chris@0 361 *
Chris@0 362 * Enable this setting to get Drupal to determine the client IP from
Chris@0 363 * the X-Forwarded-For header (or $settings['reverse_proxy_header'] if set).
Chris@0 364 * If you are unsure about this setting, do not have a reverse proxy,
Chris@0 365 * or Drupal operates in a shared hosting environment, this setting
Chris@0 366 * should remain commented out.
Chris@0 367 *
Chris@0 368 * In order for this setting to be used you must specify every possible
Chris@0 369 * reverse proxy IP address in $settings['reverse_proxy_addresses'].
Chris@0 370 * If a complete list of reverse proxies is not available in your
Chris@0 371 * environment (for example, if you use a CDN) you may set the
Chris@0 372 * $_SERVER['REMOTE_ADDR'] variable directly in settings.php.
Chris@0 373 * Be aware, however, that it is likely that this would allow IP
Chris@0 374 * address spoofing unless more advanced precautions are taken.
Chris@0 375 */
Chris@0 376 # $settings['reverse_proxy'] = TRUE;
Chris@0 377
Chris@0 378 /**
Chris@0 379 * Specify every reverse proxy IP address in your environment.
Chris@0 380 * This setting is required if $settings['reverse_proxy'] is TRUE.
Chris@0 381 */
Chris@0 382 # $settings['reverse_proxy_addresses'] = array('a.b.c.d', ...);
Chris@0 383
Chris@0 384 /**
Chris@0 385 * Set this value if your proxy server sends the client IP in a header
Chris@0 386 * other than X-Forwarded-For.
Chris@0 387 */
Chris@0 388 # $settings['reverse_proxy_header'] = 'X_CLUSTER_CLIENT_IP';
Chris@0 389
Chris@0 390 /**
Chris@0 391 * Set this value if your proxy server sends the client protocol in a header
Chris@0 392 * other than X-Forwarded-Proto.
Chris@0 393 */
Chris@0 394 # $settings['reverse_proxy_proto_header'] = 'X_FORWARDED_PROTO';
Chris@0 395
Chris@0 396 /**
Chris@0 397 * Set this value if your proxy server sends the client protocol in a header
Chris@0 398 * other than X-Forwarded-Host.
Chris@0 399 */
Chris@0 400 # $settings['reverse_proxy_host_header'] = 'X_FORWARDED_HOST';
Chris@0 401
Chris@0 402 /**
Chris@0 403 * Set this value if your proxy server sends the client protocol in a header
Chris@0 404 * other than X-Forwarded-Port.
Chris@0 405 */
Chris@0 406 # $settings['reverse_proxy_port_header'] = 'X_FORWARDED_PORT';
Chris@0 407
Chris@0 408 /**
Chris@0 409 * Set this value if your proxy server sends the client protocol in a header
Chris@0 410 * other than Forwarded.
Chris@0 411 */
Chris@0 412 # $settings['reverse_proxy_forwarded_header'] = 'FORWARDED';
Chris@0 413
Chris@0 414 /**
Chris@0 415 * Page caching:
Chris@0 416 *
Chris@0 417 * By default, Drupal sends a "Vary: Cookie" HTTP header for anonymous page
Chris@0 418 * views. This tells a HTTP proxy that it may return a page from its local
Chris@0 419 * cache without contacting the web server, if the user sends the same Cookie
Chris@0 420 * header as the user who originally requested the cached page. Without "Vary:
Chris@0 421 * Cookie", authenticated users would also be served the anonymous page from
Chris@0 422 * the cache. If the site has mostly anonymous users except a few known
Chris@0 423 * editors/administrators, the Vary header can be omitted. This allows for
Chris@0 424 * better caching in HTTP proxies (including reverse proxies), i.e. even if
Chris@0 425 * clients send different cookies, they still get content served from the cache.
Chris@0 426 * However, authenticated users should access the site directly (i.e. not use an
Chris@0 427 * HTTP proxy, and bypass the reverse proxy if one is used) in order to avoid
Chris@0 428 * getting cached pages from the proxy.
Chris@0 429 */
Chris@0 430 # $settings['omit_vary_cookie'] = TRUE;
Chris@0 431
Chris@0 432
Chris@0 433 /**
Chris@0 434 * Cache TTL for client error (4xx) responses.
Chris@0 435 *
Chris@0 436 * Items cached per-URL tend to result in a large number of cache items, and
Chris@0 437 * this can be problematic on 404 pages which by their nature are unbounded. A
Chris@0 438 * fixed TTL can be set for these items, defaulting to one hour, so that cache
Chris@0 439 * backends which do not support LRU can purge older entries. To disable caching
Chris@0 440 * of client error responses set the value to 0. Currently applies only to
Chris@0 441 * page_cache module.
Chris@0 442 */
Chris@0 443 # $settings['cache_ttl_4xx'] = 3600;
Chris@0 444
Chris@0 445 /**
Chris@0 446 * Expiration of cached forms.
Chris@0 447 *
Chris@0 448 * Drupal's Form API stores details of forms in a cache and these entries are
Chris@0 449 * kept for at least 6 hours by default. Expired entries are cleared by cron.
Chris@0 450 *
Chris@0 451 * @see \Drupal\Core\Form\FormCache::setCache()
Chris@0 452 */
Chris@0 453 # $settings['form_cache_expiration'] = 21600;
Chris@0 454
Chris@0 455 /**
Chris@0 456 * Class Loader.
Chris@0 457 *
Chris@0 458 * If the APC extension is detected, the Symfony APC class loader is used for
Chris@0 459 * performance reasons. Detection can be prevented by setting
Chris@0 460 * class_loader_auto_detect to false, as in the example below.
Chris@0 461 */
Chris@0 462 # $settings['class_loader_auto_detect'] = FALSE;
Chris@0 463
Chris@0 464 /*
Chris@0 465 * If the APC extension is not detected, either because APC is missing or
Chris@0 466 * because auto-detection has been disabled, auto-loading falls back to
Chris@0 467 * Composer's ClassLoader, which is good for development as it does not break
Chris@0 468 * when code is moved in the file system. You can also decorate the base class
Chris@0 469 * loader with another cached solution than the Symfony APC class loader, as
Chris@0 470 * all production sites should have a cached class loader of some sort enabled.
Chris@0 471 *
Chris@0 472 * To do so, you may decorate and replace the local $class_loader variable. For
Chris@0 473 * example, to use Symfony's APC class loader without automatic detection,
Chris@0 474 * uncomment the code below.
Chris@0 475 */
Chris@0 476 /*
Chris@0 477 if ($settings['hash_salt']) {
Chris@0 478 $prefix = 'drupal.' . hash('sha256', 'drupal.' . $settings['hash_salt']);
Chris@0 479 $apc_loader = new \Symfony\Component\ClassLoader\ApcClassLoader($prefix, $class_loader);
Chris@0 480 unset($prefix);
Chris@0 481 $class_loader->unregister();
Chris@0 482 $apc_loader->register();
Chris@0 483 $class_loader = $apc_loader;
Chris@0 484 }
Chris@0 485 */
Chris@0 486
Chris@0 487 /**
Chris@0 488 * Authorized file system operations:
Chris@0 489 *
Chris@0 490 * The Update Manager module included with Drupal provides a mechanism for
Chris@0 491 * site administrators to securely install missing updates for the site
Chris@0 492 * directly through the web user interface. On securely-configured servers,
Chris@0 493 * the Update manager will require the administrator to provide SSH or FTP
Chris@0 494 * credentials before allowing the installation to proceed; this allows the
Chris@0 495 * site to update the new files as the user who owns all the Drupal files,
Chris@0 496 * instead of as the user the webserver is running as. On servers where the
Chris@0 497 * webserver user is itself the owner of the Drupal files, the administrator
Chris@0 498 * will not be prompted for SSH or FTP credentials (note that these server
Chris@0 499 * setups are common on shared hosting, but are inherently insecure).
Chris@0 500 *
Chris@0 501 * Some sites might wish to disable the above functionality, and only update
Chris@0 502 * the code directly via SSH or FTP themselves. This setting completely
Chris@0 503 * disables all functionality related to these authorized file operations.
Chris@0 504 *
Chris@0 505 * @see https://www.drupal.org/node/244924
Chris@0 506 *
Chris@0 507 * Remove the leading hash signs to disable.
Chris@0 508 */
Chris@0 509 # $settings['allow_authorize_operations'] = FALSE;
Chris@0 510
Chris@0 511 /**
Chris@0 512 * Default mode for directories and files written by Drupal.
Chris@0 513 *
Chris@0 514 * Value should be in PHP Octal Notation, with leading zero.
Chris@0 515 */
Chris@0 516 # $settings['file_chmod_directory'] = 0775;
Chris@0 517 # $settings['file_chmod_file'] = 0664;
Chris@0 518
Chris@0 519 /**
Chris@0 520 * Public file base URL:
Chris@0 521 *
Chris@0 522 * An alternative base URL to be used for serving public files. This must
Chris@0 523 * include any leading directory path.
Chris@0 524 *
Chris@0 525 * A different value from the domain used by Drupal to be used for accessing
Chris@0 526 * public files. This can be used for a simple CDN integration, or to improve
Chris@0 527 * security by serving user-uploaded files from a different domain or subdomain
Chris@0 528 * pointing to the same server. Do not include a trailing slash.
Chris@0 529 */
Chris@0 530 # $settings['file_public_base_url'] = 'http://downloads.example.com/files';
Chris@0 531
Chris@0 532 /**
Chris@0 533 * Public file path:
Chris@0 534 *
Chris@0 535 * A local file system path where public files will be stored. This directory
Chris@0 536 * must exist and be writable by Drupal. This directory must be relative to
Chris@0 537 * the Drupal installation directory and be accessible over the web.
Chris@0 538 */
Chris@0 539 # $settings['file_public_path'] = 'sites/default/files';
Chris@0 540
Chris@0 541 /**
Chris@0 542 * Private file path:
Chris@0 543 *
Chris@0 544 * A local file system path where private files will be stored. This directory
Chris@0 545 * must be absolute, outside of the Drupal installation directory and not
Chris@0 546 * accessible over the web.
Chris@0 547 *
Chris@0 548 * Note: Caches need to be cleared when this value is changed to make the
Chris@0 549 * private:// stream wrapper available to the system.
Chris@0 550 *
Chris@0 551 * See https://www.drupal.org/documentation/modules/file for more information
Chris@0 552 * about securing private files.
Chris@0 553 */
Chris@0 554 # $settings['file_private_path'] = '';
Chris@0 555
Chris@0 556 /**
Chris@0 557 * Session write interval:
Chris@0 558 *
Chris@0 559 * Set the minimum interval between each session write to database.
Chris@0 560 * For performance reasons it defaults to 180.
Chris@0 561 */
Chris@0 562 # $settings['session_write_interval'] = 180;
Chris@0 563
Chris@0 564 /**
Chris@0 565 * String overrides:
Chris@0 566 *
Chris@0 567 * To override specific strings on your site with or without enabling the Locale
Chris@0 568 * module, add an entry to this list. This functionality allows you to change
Chris@0 569 * a small number of your site's default English language interface strings.
Chris@0 570 *
Chris@0 571 * Remove the leading hash signs to enable.
Chris@0 572 *
Chris@0 573 * The "en" part of the variable name, is dynamic and can be any langcode of
Chris@0 574 * any added language. (eg locale_custom_strings_de for german).
Chris@0 575 */
Chris@0 576 # $settings['locale_custom_strings_en'][''] = array(
Chris@0 577 # 'forum' => 'Discussion board',
Chris@0 578 # '@count min' => '@count minutes',
Chris@0 579 # );
Chris@0 580
Chris@0 581 /**
Chris@0 582 * A custom theme for the offline page:
Chris@0 583 *
Chris@0 584 * This applies when the site is explicitly set to maintenance mode through the
Chris@0 585 * administration page or when the database is inactive due to an error.
Chris@0 586 * The template file should also be copied into the theme. It is located inside
Chris@0 587 * 'core/modules/system/templates/maintenance-page.html.twig'.
Chris@0 588 *
Chris@0 589 * Note: This setting does not apply to installation and update pages.
Chris@0 590 */
Chris@0 591 # $settings['maintenance_theme'] = 'bartik';
Chris@0 592
Chris@0 593 /**
Chris@0 594 * PHP settings:
Chris@0 595 *
Chris@0 596 * To see what PHP settings are possible, including whether they can be set at
Chris@0 597 * runtime (by using ini_set()), read the PHP documentation:
Chris@0 598 * http://php.net/manual/ini.list.php
Chris@0 599 * See \Drupal\Core\DrupalKernel::bootEnvironment() for required runtime
Chris@0 600 * settings and the .htaccess file for non-runtime settings.
Chris@0 601 * Settings defined there should not be duplicated here so as to avoid conflict
Chris@0 602 * issues.
Chris@0 603 */
Chris@0 604
Chris@0 605 /**
Chris@0 606 * If you encounter a situation where users post a large amount of text, and
Chris@0 607 * the result is stripped out upon viewing but can still be edited, Drupal's
Chris@0 608 * output filter may not have sufficient memory to process it. If you
Chris@0 609 * experience this issue, you may wish to uncomment the following two lines
Chris@0 610 * and increase the limits of these variables. For more information, see
Chris@0 611 * http://php.net/manual/pcre.configuration.php.
Chris@0 612 */
Chris@0 613 # ini_set('pcre.backtrack_limit', 200000);
Chris@0 614 # ini_set('pcre.recursion_limit', 200000);
Chris@0 615
Chris@0 616 /**
Chris@0 617 * Active configuration settings.
Chris@0 618 *
Chris@0 619 * By default, the active configuration is stored in the database in the
Chris@0 620 * {config} table. To use a different storage mechanism for the active
Chris@0 621 * configuration, do the following prior to installing:
Chris@0 622 * - Create an "active" directory and declare its path in $config_directories
Chris@0 623 * as explained under the 'Location of the site configuration files' section
Chris@0 624 * above in this file. To enhance security, you can declare a path that is
Chris@0 625 * outside your document root.
Chris@0 626 * - Override the 'bootstrap_config_storage' setting here. It must be set to a
Chris@0 627 * callable that returns an object that implements
Chris@0 628 * \Drupal\Core\Config\StorageInterface.
Chris@0 629 * - Override the service definition 'config.storage.active'. Put this
Chris@0 630 * override in a services.yml file in the same directory as settings.php
Chris@0 631 * (definitions in this file will override service definition defaults).
Chris@0 632 */
Chris@0 633 # $settings['bootstrap_config_storage'] = array('Drupal\Core\Config\BootstrapConfigStorageFactory', 'getFileStorage');
Chris@0 634
Chris@0 635 /**
Chris@0 636 * Configuration overrides.
Chris@0 637 *
Chris@0 638 * To globally override specific configuration values for this site,
Chris@0 639 * set them here. You usually don't need to use this feature. This is
Chris@0 640 * useful in a configuration file for a vhost or directory, rather than
Chris@0 641 * the default settings.php.
Chris@0 642 *
Chris@0 643 * Note that any values you provide in these variable overrides will not be
Chris@0 644 * viewable from the Drupal administration interface. The administration
Chris@0 645 * interface displays the values stored in configuration so that you can stage
Chris@0 646 * changes to other environments that don't have the overrides.
Chris@0 647 *
Chris@0 648 * There are particular configuration values that are risky to override. For
Chris@0 649 * example, overriding the list of installed modules in 'core.extension' is not
Chris@0 650 * supported as module install or uninstall has not occurred. Other examples
Chris@0 651 * include field storage configuration, because it has effects on database
Chris@0 652 * structure, and 'core.menu.static_menu_link_overrides' since this is cached in
Chris@0 653 * a way that is not config override aware. Also, note that changing
Chris@0 654 * configuration values in settings.php will not fire any of the configuration
Chris@0 655 * change events.
Chris@0 656 */
Chris@0 657 # $config['system.file']['path']['temporary'] = '/tmp';
Chris@0 658 # $config['system.site']['name'] = 'My Drupal site';
Chris@0 659 # $config['system.theme']['default'] = 'stark';
Chris@0 660 # $config['user.settings']['anonymous'] = 'Visitor';
Chris@0 661
Chris@0 662 /**
Chris@0 663 * Fast 404 pages:
Chris@0 664 *
Chris@0 665 * Drupal can generate fully themed 404 pages. However, some of these responses
Chris@0 666 * are for images or other resource files that are not displayed to the user.
Chris@0 667 * This can waste bandwidth, and also generate server load.
Chris@0 668 *
Chris@0 669 * The options below return a simple, fast 404 page for URLs matching a
Chris@0 670 * specific pattern:
Chris@0 671 * - $config['system.performance']['fast_404']['exclude_paths']: A regular
Chris@0 672 * expression to match paths to exclude, such as images generated by image
Chris@0 673 * styles, or dynamically-resized images. The default pattern provided below
Chris@0 674 * also excludes the private file system. If you need to add more paths, you
Chris@0 675 * can add '|path' to the expression.
Chris@0 676 * - $config['system.performance']['fast_404']['paths']: A regular expression to
Chris@0 677 * match paths that should return a simple 404 page, rather than the fully
Chris@0 678 * themed 404 page. If you don't have any aliases ending in htm or html you
Chris@0 679 * can add '|s?html?' to the expression.
Chris@0 680 * - $config['system.performance']['fast_404']['html']: The html to return for
Chris@0 681 * simple 404 pages.
Chris@0 682 *
Chris@0 683 * Remove the leading hash signs if you would like to alter this functionality.
Chris@0 684 */
Chris@0 685 # $config['system.performance']['fast_404']['exclude_paths'] = '/\/(?:styles)|(?:system\/files)\//';
Chris@0 686 # $config['system.performance']['fast_404']['paths'] = '/\.(?:txt|png|gif|jpe?g|css|js|ico|swf|flv|cgi|bat|pl|dll|exe|asp)$/i';
Chris@0 687 # $config['system.performance']['fast_404']['html'] = '<!DOCTYPE html><html><head><title>404 Not Found</title></head><body><h1>Not Found</h1><p>The requested URL "@path" was not found on this server.</p></body></html>';
Chris@0 688
Chris@0 689 /**
Chris@0 690 * Load services definition file.
Chris@0 691 */
Chris@0 692 $settings['container_yamls'][] = $app_root . '/' . $site_path . '/services.yml';
Chris@0 693
Chris@0 694 /**
Chris@0 695 * Override the default service container class.
Chris@0 696 *
Chris@0 697 * This is useful for example to trace the service container for performance
Chris@0 698 * tracking purposes, for testing a service container with an error condition or
Chris@0 699 * to test a service container that throws an exception.
Chris@0 700 */
Chris@0 701 # $settings['container_base_class'] = '\Drupal\Core\DependencyInjection\Container';
Chris@0 702
Chris@0 703 /**
Chris@0 704 * Override the default yaml parser class.
Chris@0 705 *
Chris@0 706 * Provide a fully qualified class name here if you would like to provide an
Chris@0 707 * alternate implementation YAML parser. The class must implement the
Chris@0 708 * \Drupal\Component\Serialization\SerializationInterface interface.
Chris@0 709 */
Chris@0 710 # $settings['yaml_parser_class'] = NULL;
Chris@0 711
Chris@0 712 /**
Chris@0 713 * Trusted host configuration.
Chris@0 714 *
Chris@0 715 * Drupal core can use the Symfony trusted host mechanism to prevent HTTP Host
Chris@0 716 * header spoofing.
Chris@0 717 *
Chris@0 718 * To enable the trusted host mechanism, you enable your allowable hosts
Chris@0 719 * in $settings['trusted_host_patterns']. This should be an array of regular
Chris@0 720 * expression patterns, without delimiters, representing the hosts you would
Chris@0 721 * like to allow.
Chris@0 722 *
Chris@0 723 * For example:
Chris@0 724 * @code
Chris@0 725 * $settings['trusted_host_patterns'] = array(
Chris@0 726 * '^www\.example\.com$',
Chris@0 727 * );
Chris@0 728 * @endcode
Chris@0 729 * will allow the site to only run from www.example.com.
Chris@0 730 *
Chris@0 731 * If you are running multisite, or if you are running your site from
Chris@0 732 * different domain names (eg, you don't redirect http://www.example.com to
Chris@0 733 * http://example.com), you should specify all of the host patterns that are
Chris@0 734 * allowed by your site.
Chris@0 735 *
Chris@0 736 * For example:
Chris@0 737 * @code
Chris@0 738 * $settings['trusted_host_patterns'] = array(
Chris@0 739 * '^example\.com$',
Chris@0 740 * '^.+\.example\.com$',
Chris@0 741 * '^example\.org$',
Chris@0 742 * '^.+\.example\.org$',
Chris@0 743 * );
Chris@0 744 * @endcode
Chris@0 745 * will allow the site to run off of all variants of example.com and
Chris@0 746 * example.org, with all subdomains included.
Chris@0 747 */
Chris@0 748
Chris@0 749 /**
Chris@0 750 * The default list of directories that will be ignored by Drupal's file API.
Chris@0 751 *
Chris@0 752 * By default ignore node_modules and bower_components folders to avoid issues
Chris@0 753 * with common frontend tools and recursive scanning of directories looking for
Chris@0 754 * extensions.
Chris@0 755 *
Chris@0 756 * @see file_scan_directory()
Chris@0 757 * @see \Drupal\Core\Extension\ExtensionDiscovery::scanDirectory()
Chris@0 758 */
Chris@0 759 $settings['file_scan_ignore_directories'] = [
Chris@0 760 'node_modules',
Chris@0 761 'bower_components',
Chris@0 762 ];
Chris@0 763
Chris@0 764 /**
Chris@0 765 * The default number of entities to update in a batch process.
Chris@0 766 *
Chris@0 767 * This is used by update and post-update functions that need to go through and
Chris@0 768 * change all the entities on a site, so it is useful to increase this number
Chris@0 769 * if your hosting configuration (i.e. RAM allocation, CPU speed) allows for a
Chris@0 770 * larger number of entities to be processed in a single batch run.
Chris@0 771 */
Chris@0 772 $settings['entity_update_batch_size'] = 50;
Chris@0 773
Chris@0 774 /**
Chris@0 775 * Load local development override configuration, if available.
Chris@0 776 *
Chris@0 777 * Use settings.local.php to override variables on secondary (staging,
Chris@0 778 * development, etc) installations of this site. Typically used to disable
Chris@0 779 * caching, JavaScript/CSS compression, re-routing of outgoing emails, and
Chris@0 780 * other things that should not happen on development and testing sites.
Chris@0 781 *
Chris@0 782 * Keep this code block at the end of this file to take full effect.
Chris@0 783 */
Chris@0 784 #
Chris@0 785 # if (file_exists($app_root . '/' . $site_path . '/settings.local.php')) {
Chris@0 786 # include $app_root . '/' . $site_path . '/settings.local.php';
Chris@0 787 # }