diff --git a/packages/playground/remote/src/lib/worker-thread.ts b/packages/playground/remote/src/lib/worker-thread.ts index cf56ceca62..6cc759a6fc 100644 --- a/packages/playground/remote/src/lib/worker-thread.ts +++ b/packages/playground/remote/src/lib/worker-thread.ts @@ -12,7 +12,7 @@ import { preloadSqliteIntegration, wordPressRewriteRules, } from '@wp-playground/wordpress'; -import { PHPRequestHandler } from '@php-wasm/universal'; +import { PHPRequestHandler, withPHPIniValues } from '@php-wasm/universal'; import { SyncProgressCallback, bindOpfs, @@ -21,6 +21,7 @@ import { import { defineSiteUrl, defineWpConfigConsts, + runWpInstallationWizard, unzip, } from '@wp-playground/blueprints'; @@ -228,6 +229,34 @@ try { new File([sqliteIntegrationZip], 'sqlite.zip') ); + // Install WordPress if it isn't installed yet + const isInstalled = + ( + await primaryPhp.run({ + code: ` + await runWpInstallationWizard(primaryPhp, { + options: {}, + }) + ); + } + // Always setup the current site URL. await defineSiteUrl(primaryPhp, { siteUrl: scopedSiteUrl, diff --git a/packages/playground/wordpress-builds/src/sqlite-database-integration/get-sqlite-database-plugin-details.ts b/packages/playground/wordpress-builds/src/sqlite-database-integration/get-sqlite-database-plugin-details.ts index 29f6ecb16c..531e5b39f5 100644 --- a/packages/playground/wordpress-builds/src/sqlite-database-integration/get-sqlite-database-plugin-details.ts +++ b/packages/playground/wordpress-builds/src/sqlite-database-integration/get-sqlite-database-plugin-details.ts @@ -1,4 +1,3 @@ - // @ts-ignore import url from './sqlite-database-integration.zip?url'; @@ -10,4 +9,3 @@ import url from './sqlite-database-integration.zip?url'; */ export const size = 83956; export { url }; -