Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WordPress: Use the secure URL for WP_HOME #1854

Merged
merged 2 commits into from Nov 7, 2019
Merged

WordPress: Use the secure URL for WP_HOME #1854

merged 2 commits into from Nov 7, 2019

Conversation

gormus
Copy link
Contributor

@gormus gormus commented Sep 28, 2019

The Problem/Issue/Bug:

Every time I run ddev config, DDEV overrides the wp-config-ddev.php for the WP_HOME constant, and uses HTTP protocol for that URL.
However DDEV already defaults to secure URLs, this setting should match that too.

How this PR Solves The Problem:

Changes DeployURL to use a secure URL, so that WP_HOME can inherit that too.

@CLAassistant
Copy link

CLAassistant commented Sep 28, 2019

CLA assistant check
All committers have signed the CLA.

@rfay
Copy link
Member

rfay commented Sep 30, 2019

Seems reasonable to me.

I see this actually ends up getting used as $WP_HOME at https://github.com/drud/ddev/blob/2948e7e5d250abfc85dbed76e5af6804e15a912c/pkg/ddevapp/wordpress.go#L143

@rfay
Copy link
Member

rfay commented Oct 5, 2019

In #1862 DDEV_PRIMARY_URL and app.GetPrimaryURL() are introduced. I think that will be better to use than just using the secure URL by default.

@rfay
Copy link
Member

rfay commented Oct 22, 2019

#1862 has landed, so this can now use the primary URL, will take a look a bit later. In the meantime, rebased this to current upstream/master.

@rfay
Copy link
Member

rfay commented Oct 25, 2019

I took the liberty of rebasing this and using the app.GetPrimaryURL(). However, it doesn't actually work yet with WP because of the basic problem described in #1736 - we need to get that one fixed before this has any value.

@rfay rfay changed the title Use the secure URL for WP_HOME WordPress: Use the secure URL for WP_HOME Oct 28, 2019
gormus and others added 2 commits November 6, 2019 16:40
Since DDEV instances default to `https`, it makes sense to keep `WP_HOME` the same.
Copy link
Member

@rfay rfay left a comment

Choose a reason for hiding this comment

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

This is ready to go now when tests complete. And #1736 is in progress.

@rfay rfay merged commit 62d39e6 into ddev:master Nov 7, 2019
@gormus gormus deleted the patch-1 branch November 7, 2019 23:32
rfay pushed a commit to rfay/ddev that referenced this pull request Jan 15, 2020
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.

None yet

3 participants