Skip to content

Always generate settings file unless it's custom, fixes #308 - #325

Merged
rfay merged 4 commits into
ddev:masterfrom
rfay:20170614_manage_settings
Jun 15, 2017
Merged

rfay merged 4 commits into
ddev:masterfrom
rfay:20170614_manage_settings

Conversation

@rfay

@rfay rfay commented Jun 14, 2017 •

Copy link
Copy Markdown
Member

The Problem:

OP #308 : We can go ahead and update the Drupal/WP settings file if we created it in the first place. This will allow for better backward compatibility if things happen like the db host or permissions change.

The Fix:

  • Introduces the string #ddev-generated as a signature
  • If #ddev-generated is not found in the settings, we don't touch it (and people can configure to their heart's delight)
  • If we find #ddev-generated (or if a settings file does not exist), we can always recreate the settings file.
  • Remove automatic include of custom settings files (like settings.local.php) which are likely to contain things that just break the site in the ddev context.

The Test:

Automation Overview:

Related Issue Link(s):

OP #308

Release/Deployment notes:

@rfay rfay self-assigned this Jun 14, 2017
@rfay
rfay requested a review from tannerjfco June 14, 2017 22:26

@tannerjfco tannerjfco left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems like we should have a test for FgrepStringInFile(). Otherwise, this all looks good and worked as I expected.

@rfay

rfay commented Jun 15, 2017

Copy link
Copy Markdown
Member Author

Good catch, test added in 347c0ed, thanks.

@rfay
rfay merged commit 9bb9629 into ddev:master Jun 15, 2017
@rfay
rfay deleted the 20170614_manage_settings branch June 15, 2017 22:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants