fix: Deployment Failure and pipeline failure for CPAsh#628
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR improves deployment reliability by tightening Azure OpenAI quota prechecks, expanding supported deployment regions, and simplifying CI/CD handling around quota outcomes.
Changes:
- Rewrites
infra/scripts/checkquota.shto select a deployable region (with fallback) and export results for workflows. - Updates quota-check defaults/messaging in
infra/scripts/quota_check_params.shto align with the Bicep-allowed region set. - Extends Bicep region support (adds
swedencentral) and adjusts private-endpoint module dependencies; simplifies workflow quota-failure detection.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| infra/scripts/quota_check_params.sh | Updates default region list and enhances user-facing quota failure/success messaging + CI env exports. |
| infra/scripts/checkquota.sh | Replaces the quota-check logic with a region-selection flow and CI-friendly outputs. |
| infra/main.bicep | Adds swedencentral to allowed locations/replica pairs; adds explicit dependencies for AI Services private endpoint module. |
| infra/main_custom.bicep | Mirrors main.bicep changes for custom deployments (region + dependency updates). |
| .github/workflows/job-deploy.yml | Simplifies quota failure detection logic in the deployment job workflow. |
| .github/workflows/deploy.yml | Simplifies quota failure detection logic in the deployment workflow. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Roopan-Microsoft
approved these changes
Jun 17, 2026
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.
This pull request enhances Azure region quota checking and deployment workflows to improve reliability, user feedback, and support for additional regions. The main changes include a major rewrite of the
checkquota.shscript for better region selection and error handling, updates to Bicep files for new region support, and improved CI/CD integration.Quota Checking Improvements:
infra/scripts/checkquota.sh: Completely rewritten to prioritize user-specified regions, automatically fall back to allowed regions, and provide clear feedback on quota status. The script now exports the selected region and failure flags for CI/CD, and gives actionable guidance when quota is insufficient. [1] [2]infra/scripts/quota_check_params.sh: Updates output messaging for clarity, aligns region lists with deployment parameters, and ensures CI/CD environment variables are set appropriately on failure or success. [1] [2] [3]Region Support and Deployment Logic:
infra/main.bicep,infra/main_custom.bicep: Addsswedencentralto allowed regions and replica region pairs, expanding deployment options. [1] [2] [3] [4]infra/main.bicep,infra/main_custom.bicep: Updates module dependencies to ensure correct deployment order when private networking is enabled. [1] [2]CI/CD Workflow Adjustments:
.github/workflows/deploy.yml,.github/workflows/job-deploy.yml: Simplifies quota failure detection and ensures the correct environment flags are set for downstream steps. [1] [2]These changes collectively make quota checks more robust, improve deployment flexibility, and enhance the developer/operator experience during deployment.## Purpose
Does this introduce a breaking change?
Golden Path Validation
Deployment Validation
What to Check
Verify that the following are valid
Other Information