Acquia Copilot is a conversational AI connected into our product documentation and knowledge base. Ask Copilot about product features, technical details, troubleshooting and how to get started with Acquia products.
Applications on Cloud Platform load a specific set of global configurations to ensure minimum basic operations are fulfilled. This configuration exists in your application’s settings.php file and looks similar to the following:
// On Cloud Platform, this include file configures Drupal to use the correct
// database in each site environment (Dev, Stage, or Prod). To use this
// settings.php for development on your local workstation, set $databases
// (Drupal 7 or 9+) as described in comments above.
if (file_exists('/var/www/site-php')) {
require('/var/www/site-php/myapp/myapp-settings.inc');
}
Ensure that you add the require line in your settings.php file. Otherwise, the system displays the following error:
The Settings file is not writable. The Drupal installer requires write permissions to ./sites/default/settings.php during the installation process. The webhosting issues documentation section offers help on this and other topics.
Important
The require line includes files and such files include variables with specific values. To override such values, you must add your custom values for the variables after the require line.
For example, by default, the config_sync_directory value is set to sites/default/files/config_xxxxx. To change this value, you must include the require line and add your custom line to override the system-defined value. The following code snippet shows how you can override the system-defined value for config_sync_directory with config directory above your docroot.
Any modifications made to the settings.php file should be placed after this require line. Modifications made before the require line may be overridden by Acquia’s required file.
The file added by the Acquia require line performs the following functions:
Ensures that a valid version of Drupal core is installed.
Determines what version of Drupal core is in use.
Establishes the trusted host patterns for Drupal.
Establishes the Memcached infrastructure and connection information.
Builds all of the database connection information.
Suppresses error reporting in the production environment.
Applications on Cloud Platform load a specific set of global configurations to ensure minimum basic operations are fulfilled. This configuration exists in your application’s settings.php file and looks similar to the following:
// On Cloud Platform, this include file configures Drupal to use the correct
// database in each site environment (Dev, Stage, or Prod). To use this
// settings.php for development on your local workstation, set $databases
// (Drupal 7 or 9+) as described in comments above.
if (file_exists('/var/www/site-php')) {
require('/var/www/site-php/myapp/myapp-settings.inc');
}
Ensure that you add the require line in your settings.php file. Otherwise, the system displays the following error:
The Settings file is not writable. The Drupal installer requires write permissions to ./sites/default/settings.php during the installation process. The webhosting issues documentation section offers help on this and other topics.
Important
The require line includes files and such files include variables with specific values. To override such values, you must add your custom values for the variables after the require line.
For example, by default, the config_sync_directory value is set to sites/default/files/config_xxxxx. To change this value, you must include the require line and add your custom line to override the system-defined value. The following code snippet shows how you can override the system-defined value for config_sync_directory with config directory above your docroot.
Any modifications made to the settings.php file should be placed after this require line. Modifications made before the require line may be overridden by Acquia’s required file.
The file added by the Acquia require line performs the following functions:
Ensures that a valid version of Drupal core is installed.
Determines what version of Drupal core is in use.
Establishes the trusted host patterns for Drupal.
Establishes the Memcached infrastructure and connection information.
Builds all of the database connection information.
Suppresses error reporting in the production environment.