Add Deployment Precheck feature with documentation#357
Merged
Wiesenwischer merged 8 commits intomainfrom Apr 2, 2026
Merged
Conversation
Pre-flight checks before deployment to verify infrastructure readiness
before the point of no return (container removal).
Domain: PrecheckResult, PrecheckItem, PrecheckSeverity value objects
Rules: 6 precheck rules (ImageAvailability, PortConflict, VariableValidation,
NetworkAvailability, VolumeStatus, ExistingDeployment)
API: POST /api/environments/{envId}/stacks/{stackId}/precheck endpoint
Hooks: Automatic precheck before hook deploys, dryRun parameter, 422 on errors
UI: PrecheckPanel component, auto-run on deploy flow entry, Re-Check button,
deploy button disabled when precheck has errors
Tests: 53 unit tests covering all rules, result aggregation, and edge cases
- Add E2E test suite (6 tests) covering precheck panel, severity icons, re-check button, deploy button state, loading state, and custom deploy - Capture 6 screenshots for step-by-step documentation - Add German and English docs pages under deployments/deployment-precheck - Update docs index pages with precheck links - Add Deployment Precheck as highlighted feature on landing page with NEW badge, translations (DE/EN), and shield-check icon
Extend PLAN-deployment-precheck.md with product precheck support: - Feature 8: Backend endpoint + MediatR handler for product precheck - Feature 9: UI integration with useProductPrecheck hook + DeployProduct.tsx - Feature 10: Unit, integration, and E2E tests for product precheck
Extend deployment precheck to support product deployments with multiple
stacks. The backend orchestrates per-stack prechecks in parallel via
MediatR and aggregates results. The UI auto-runs precheck on the
DeployProduct page and blocks deployment when any stack has errors.
Backend:
- ProductPrecheckResult domain value object with stack-level aggregation
- RunProductPrecheckQuery handler: loads product, merges variables,
dispatches RunDeploymentPrecheckQuery per stack in parallel
- POST /api/environments/{envId}/product-deployments/precheck endpoint
Frontend:
- runProductPrecheck() API client in @rsgo/core
- useProductPrecheck hook for product precheck state management
- ProductPrecheckPanel component with per-stack accordion view
- DeployProduct.tsx: hybrid trigger (auto-run + re-check), deploy
button disabled on errors
Tests:
- 7 unit tests for ProductPrecheckResult aggregation
- 10 unit tests for RunProductPrecheckHandler (variable merging,
parallel execution, error handling, edge cases)
- 3 integration tests for ProductPrecheckEndpoint
Bug fix: All precheck rules (PortConflict, ImageAvailability,
VolumeStatus, NetworkAvailability) now resolve ${VARIABLE} placeholders
in port mappings, image names, volume sources, and network names before
validation. Previously, unresolved placeholders like ${FRONTEND_PORT}
silently failed int.TryParse and port conflicts were never detected.
UX redesign: Precheck no longer auto-runs on the deploy page. Instead,
a "Run Precheck" button in the sidebar navigates to a dedicated precheck
results page (/deploy/:stackId/precheck, /deploy-product/:productId/precheck).
Deploy button is always enabled — precheck is advisory, not blocking.
Contributor
🚀 Cloudflare Pages PreviewPreview deployment ready! |
Update E2E tests and screenshots to reflect the new precheck workflow: - Run Precheck button in sidebar instead of auto-run - Dedicated precheck results page instead of inline panel - Deploy button always enabled (precheck is advisory) New screenshots: run-button, results page, recheck, deploy-enabled. Remove old screenshots from the auto-run inline flow. Update DE + EN documentation with new step-by-step guide.
ImageAvailabilityRule now uses IRegistryCredentialProvider to look up configured credentials before checking registry access. Previously it only performed anonymous checks, causing false "auth required" errors for private registries with valid credentials configured.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
PrecheckResult,PrecheckItem,PrecheckSeverity,ProductPrecheckResultvalue objectsPOST /api/.../precheckfor single stacks and products, plusdryRunsupport on/api/hooks/deployPrecheckPanelandProductPrecheckPanelcomponents,usePrecheck/useProductPrecheckhooks, standalone precheck pages, auto-run on deploy page with Re-Check buttonTest plan
dotnet test)npm run build)