Skip to content

redis/scripts/setup-drupal-settings.sh creates settings.php incorrectly if it is not alreay present #20

@drakythe

Description

@drakythe

Ran into an issue today setting up a ddev environment for drupal with redis. If the ddev get ddev/ddev-redis command is issued before the ddev start command the setup-drupal-settings.sh file ends up creating a settings.php file with only its configuration in there. The ddev start command then appends the standard settings.ddev.php stuff in there as well. However, the drupal site will fail to install because the settings.php file created by the redis script was done so without copying the default.settings.php or even adding in the php open tag, so drupal fails to install as it cannot find a valid database connection string since the settings.php without the opening php tags won't properly load in settings.ddev php.

Proposed fix would be to adjust the script to check for the existence of settings.php and if it does not exist then create it by copying default.settings.php before appending the redis settings to the file.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions