Is it OK to delete the 'active' and 'staging' entries automatically created in settings.php? I don't plan on using them, but it's not clear to me whether some process might expect them to exist.
The default.settings.php file contains the following comment:
The staging directory is used for configuration imports; the active directory is not used by default, since the default storage for active configuration is the database rather than the file system (this can be changed; see "Active configuration settings" below).
- The staging directory is used only when importing configuration from the UI
- The active directory is not used by default from Drupal 8, which saves the configuration data in the database, like Drupal 7 did with the persistent variables
In both the cases, I would expect Drupal to correctly handle the case the global
$config_directories is not set.
Sadly, D8 will fail with the following exception, if you delete the active element from the array.
Exception: The configuration directory type active does not exist. in config_get_config_directory() (line 177 of core/includes/bootstrap.inc).
However, it doesn't seem to mind if you remove the
staging entry. It's worth noting that
drush 7 documentation says that the
staging entry will be used by default when executing commands like
config-export (drush 8, currently presents a nice menu listing all the
config_directories instead of defaulting; but it's still in beta so the behavior may change).