wpstarter
wpstarter copied to clipboard
When using with the DDev tool WP Starter v3 doesn't recognize `WP_HOME` as being set
https://github.com/wecodemore/wpstarter/blob/ad004f7693be9c3bf3b2fbc64a48b506ff33b4c7/templates/wp-config.php#L219-L230
This file: https://github.com/ddev/ddev/blob/master/pkg/ddevapp/wordpress/wp-config-ddev.php
is being included in the ENV_VARIABLES section as so:
// Include for ddev-managed settings in wp-config-ddev.php.
$ddev_settings = dirname( __FILE__ ) . '/wp-config-ddev.php';
if ( is_readable( $ddev_settings ) && ! defined( 'DB_USER' ) ) {
require_once $ddev_settings;
}
@timnolte first basic question, have you verified that getenv('IS_DDEV_PROJECT') returns "true" when the faile is loaded?
@gmazzap well, so here's the thing, if we manually setup on line 225:
$home .= $_SERVER['SERVER_NAME'] ?? '<PROJECT_ID>.ddev.site';
The site loads properly along with all of the database settings. It would seem to me then that URL_CONSTANTS is being loaded before ENV_VARIABLES.