[#2597] Replaced post-provision scripts with deploy steps via the 'drupal/deploy_steps' module.#2606
[#2597] Replaced post-provision scripts with deploy steps via the 'drupal/deploy_steps' module.#2606AlexSkrypnyk wants to merge 38 commits into
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. 🗂️ Base branches to auto review (1)
Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository UI Review profile: ASSERTIVE Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
2 similar comments
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
📖 Documentation preview for this pull request has been deployed to Netlify: https://6a2e5f7d03b4015735467740--vortex-docs.netlify.app This preview is rebuilt on every commit and is not the production documentation site. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
2 similar comments
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
2 similar comments
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## 2.x #2606 +/- ##
==========================================
- Coverage 86.24% 85.97% -0.27%
==========================================
Files 88 86 -2
Lines 4537 4415 -122
Branches 3 3
==========================================
- Hits 3913 3796 -117
+ Misses 624 619 -5 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This comment has been minimized.
This comment has been minimized.
2 similar comments
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
2 similar comments
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
2 similar comments
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
2 similar comments
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
Code coverage (threshold: 90%) Per-class coverage |
This comment has been minimized.
This comment has been minimized.
2 similar comments
|
Code coverage (threshold: 90%) Per-class coverage |
|
Code coverage (threshold: 90%) Per-class coverage |
Closes #2597
Summary
Replaces the bespoke post-provision shell scripts with Drupal-native "run on every deploy" logic built on the
drupal/deploy_stepscontributed module. The two example provision scripts becomeDeployStepplugins - the development/demo environment setup (ys_base) and the content migration (ys_migrate) - discovered and run bydeploy_stepsaround everydrush deploy:hook, grouped by phase (pre/post), ordered by weight, each gated by an explicit, logged skip reason.deploy_stepswas extracted from this work into a standalone contrib module; Vortex now consumes it as a Composer dependency rather than shipping the mechanism in-repo. Theprovision-*.shdiscovery loop is removed from the provision orchestrator, which now enables the module and the site modules beforedeploy:hookso their plugins and run-oncehook_deploy_NAME()run in the same pass.Changes
Dependency
composer require drupal/deploy_stepswith an explicit^1.0.0-alpha1constraint (the module's current release; the explicit alpha suffix is required because the project isminimum-stability: stable).config.audit.ignorefor twoguzzlehttp/psr7advisories (GHSA-34xg-wgjx-8xph,GHSA-hq7v-mx3g-29hw) - a transitive dependency ofdrupal/core-recommendedthatblock-insecurerejects until an upstream release moves off the affected 2.8.x. Temporary; remove when resolved upstream.Deploy step plugins (consumers)
web/modules/custom/ys_base/src/Plugin/DeployStep/DevelopmentSetup.php- theprovision-10-example.shlogic (PRE phase, non-production): set the site name and install the contrib/service/ys_search/ys_demomodules. Installer service/module tokens preserved as PHP-comment fences. Running in the PRE phase means the modules it enables have their run-once deploy hooks fired by thedeploy:hookbody.web/modules/custom/ys_migrate/src/Plugin/DeployStep/MigrateContent.php- theprovision-20-migration.shlogic (POST phase, non-production): amigrate:importshaped byDRUPAL_MIGRATION_*variables, plus a guard that loads thedb2.sqlsource database into themigrateconnection when it is not already populated.DrushTrait,EnvTrait,EnvironmentTrait) and useskip()for conditional, logged skips.deploy_stepsdependency; the install profile depends on it too.scripts/provision-10-example.shandscripts/provision-20-migration.shremoved.Provision orchestrator (
.vortex/tooling/src/provision)for file in provision-*.shdiscovery loop and theVORTEX_PROVISION_SCRIPTS_DIRvariable.deploy:hook, enabledeploy_stepsand the always-on site modules (resolved by glob*_base/*_migrate, since the installer renames them).Tooling, tests, docs
rector.php: skipPrivatizeFinalClassConstantRector,RenamePropertyToMatchTypeRector, andRenameForeachValueVariableToMatchMethodCallReturnTypeRector, beside the privatization/rename rules the config already excludes; class constants carry explicit types.provision-migration.batsremoved,provision.batstrimmed),MigrationHandlerProcessTest, and theModules/Migrationinstaller handlers updated to the plugin model.docs/deployment.md, the docs-siteprovision.mdx/migrations.mdx,scripts/README.md, and.vortex/tooling/README.mddocument the deploy-step model; the orphanedprovision-example.shdoc asset removed.Before / After