- Issue created by @DamienMcKenna
There's a confusion on how the site installation should work when using an installation profile and a fully functioning exported configuration.
Scenario 1:
* Installation profile with a "config/sync" directory containing the fully working site config.
* The following in settings.php: $settings['config_sync_directory'] = 'profiles/myinstaller/config/sync';
When the installer is opened, two options are presented:
* The name of the installation profile.
* An option that says "Install from existing configuration".
Both result in the same results - the site is installed as expected.
Issue 1: there should only be one option shown.
Scenario 2:
* Installation profile with a "config/install" directory containing the fully working site config.
* The following in settings.php: $settings['config_sync_directory'] = 'profiles/myinstaller/config/install';
When the installer is opened, one option is presented:
* The name of the installation profile.
The install fails immediately with this error:
Drupal\Core\Database\DatabaseExceptionWrapper: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'db.sessions' doesn't exist: SELECT "session" FROM "sessions" WHERE "sid" = :sid LIMIT 0, 1; Array ( [:sid] => o9PS8MFItCuIS8Pk7zKJ0Z4g7nis34xEFy7pO65WOl4 ) in Drupal\Core\Session\SessionHandler->read() (line 62 of core/lib/Drupal/Core/Session/SessionHandler.php).
Scenario 3:
* Installation profile with no "config" directory.
* Site configuration stored in "config/sync".
* The following in settings.php: $settings['config_sync_directory'] = 'config/sync';
When the installer is opened, one option is presented:
* The name of the installation profile.
The install fails immediately with this error:
Drupal\Core\Database\DatabaseExceptionWrapper: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'db.sessions' doesn't exist: SELECT "session" FROM "sessions" WHERE "sid" = :sid LIMIT 0, 1; Array ( [:sid] => o9PS8MFItCuIS8Pk7zKJ0Z4g7nis34xEFy7pO65WOl4 ) in Drupal\Core\Session\SessionHandler->read() (line 62 of core/lib/Drupal/Core/Session/SessionHandler.php).
Have an install profile which contains a exported configuration.
When running a site installation:
* If $settings['config_sync_directory'] is defined and points to a valid installation path, that config may be used to run the installation.
* If $settings['config_sync_directory'] is not defined the installation profile is used as normal and the option to use the exported configuration is not presented on the installer page.
Work out the correct approach to doing this.
TBD
TBD
TBD
TBD
Active
11.0 π₯