diff --git a/config/runner.yml b/config/runner.yml index 65b96b55..d49c4eef 100644 --- a/config/runner.yml +++ b/config/runner.yml @@ -22,7 +22,7 @@ drupal: root: "build" root_absolute: ~ base_url: "http://127.0.0.1:8888" - settings_local_file: 'settings.local.php' + settings_local_file: '/sites/default/settings.override.php' # Basic Drupal site information. site: diff --git a/src/Commands/DrupalCommands.php b/src/Commands/DrupalCommands.php index c241a0ad..12b81f9d 100644 --- a/src/Commands/DrupalCommands.php +++ b/src/Commands/DrupalCommands.php @@ -283,12 +283,12 @@ public function settingsSetup(array $options = [ ]) { $settings_file = $options['root'].'/sites/default/settings.php'; - $settings_local_file = $options['root'] . '/sites/default/' . $this->getConfig()->get('drupal.settings_local_file'); + $settings_local_file = $options['root'] . $this->getConfig()->get('drupal.settings_local_file'); return $this->collectionBuilder()->addTaskList([ - $this->taskFilesystemStack()->copy($options['root'] . '/sites/default/default.settings.php', $settings_file), + $this->taskFilesystemStack()->copy($options['root'] . '/sites/default/default.settings.php', $settings_file, true), $this->taskWriteToFile($settings_file)->append()->lines([ - 'if (file_exists($app_root . \'/\' . $site_path . \'/' . $settings_local_file . '\')) {', - ' include $app_root . \'/\' . $site_path . \'/' . $settings_local_file . '\';', + 'if (file_exists($app_root . \'' . $settings_local_file . '\')) {', + ' include $app_root . \'' . $settings_local_file . '\';', '}' ]), $this->taskWriteToFile($settings_local_file)->lines([