Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions packages/env/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
### Bug Fixes

- Add MySQL healthcheck to prevent race condition where WordPress containers start before MySQL is fully initialized. Uses MariaDB's official `healthcheck.sh` script with `MARIADB_AUTO_UPGRADE` to support both new and existing installations.
- Remove non-functional `WP_ENV_MULTISITE` config.

### Breaking Changes

Expand Down
2 changes: 1 addition & 1 deletion packages/env/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -785,7 +785,7 @@ You can tell `wp-env` to use a specific PHP version for compatibility and testin

### Multisite support

You can tell `wp-env` if the site should be multisite enabled. This can also be set via the environment variable `WP_ENV_MULTISITE`.
You can tell `wp-env` if the site should be multisite enabled.

```json
{
Expand Down
5 changes: 0 additions & 5 deletions packages/env/lib/config/get-config-from-environment-vars.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ const { checkPort, checkVersion, checkString } = require( './validate-config' );
* @property {?number} phpmyadminPort An override for the development environment's phpMyAdmin port.
* @property {?WPSource} coreSource An override for all environment's coreSource.
* @property {?string} phpVersion An override for all environment's PHP version.
* @property {?boolean} multisite An override for if environmen should be multisite.
* @property {?Object.<string, string>} lifecycleScripts An override for various lifecycle scripts.
*/

Expand Down Expand Up @@ -69,10 +68,6 @@ module.exports = function getConfigFromEnvironmentVars( cacheDirectoryPath ) {
environmentConfig.phpVersion = process.env.WP_ENV_PHP_VERSION;
}

if ( process.env.WP_ENV_MULTISITE ) {
environmentConfig.multisite = !! process.env.WP_ENV_MULTISITE;
}

return environmentConfig;
};

Expand Down
6 changes: 6 additions & 0 deletions packages/env/lib/config/parse-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -314,6 +314,12 @@ function getEnvironmentVarOverrides( cacheDirectoryPath ) {
overrideConfig.env.tests.phpVersion = overrides.phpVersion;
}

if ( overrides.multisite ) {
overrideConfig.multisite = overrides.multisite;
overrideConfig.env.development.multisite = overrides.multisite;
overrideConfig.env.tests.multisite = overrides.multisite;
}

return overrideConfig;
}

Expand Down
Loading