Skip to content

Commit bcec9db

Browse files
Merge pull request #970 from microsoft/dev-v4
fix: Dev v4 to main merge
2 parents 92b0f85 + 417248a commit bcec9db

17 files changed

Lines changed: 493 additions & 43 deletions

File tree

.github/workflows/validate-bicep-params.yml

Lines changed: 23 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,16 @@ jobs:
3434
- name: Validate infra/ parameters
3535
id: validate_infra
3636
continue-on-error: true
37+
env:
38+
ACCELERATOR_NAME: ${{ env.accelerator_name }}
3739
run: |
3840
set +e
39-
python infra/scripts/validate_bicep_params.py --dir infra --strict --no-color --json-output infra_results.json 2>&1 | tee infra_output.txt
41+
RUN_URL="https://github.com/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID}"
42+
python infra/scripts/validate_bicep_params.py --dir infra --strict --no-color \
43+
--json-output infra_results.json \
44+
--html-output email_body.html \
45+
--accelerator-name "${ACCELERATOR_NAME}" \
46+
--run-url "${RUN_URL}" 2>&1 | tee infra_output.txt
4047
EXIT_CODE=${PIPESTATUS[0]}
4148
set -e
4249
echo "## Infra Param Validation" >> "$GITHUB_STEP_SUMMARY"
@@ -61,24 +68,25 @@ jobs:
6168
name: bicep-validation-results
6269
path: |
6370
infra_results.json
71+
email_body.html
6472
retention-days: 30
6573

6674
- name: Send schedule notification on failure
6775
if: github.event_name == 'schedule' && steps.result.outputs.status == 'failure'
6876
env:
6977
LOGICAPP_URL: ${{ secrets.EMAILNOTIFICATION_LOGICAPP_URL_TA }}
70-
GITHUB_REPOSITORY: ${{ github.repository }}
71-
GITHUB_RUN_ID: ${{ github.run_id }}
7278
ACCELERATOR_NAME: ${{ env.accelerator_name }}
7379
run: |
74-
RUN_URL="https://github.com/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID}"
75-
INFRA_OUTPUT=$(sed 's/&/\&amp;/g; s/</\&lt;/g; s/>/\&gt;/g' infra_output.txt)
80+
if [ -f email_body.html ]; then
81+
EMAIL_BODY=$(cat email_body.html)
82+
else
83+
EMAIL_BODY="<p>Bicep parameter validation failed but no HTML report was generated. Check the <a href=\"https://github.com/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID}\">workflow run</a> for details.</p>"
84+
fi
7685
7786
jq -n \
7887
--arg name "${ACCELERATOR_NAME}" \
79-
--arg infra "$INFRA_OUTPUT" \
80-
--arg url "$RUN_URL" \
81-
'{subject: ("Bicep Parameter Validation Report - " + $name + " - Issues Detected"), body: ("<p>Dear Team,</p><p>The scheduled <strong>Bicep Parameter Validation</strong> for <strong>" + $name + "</strong> has detected parameter mapping errors.</p><p><strong>infra/ Results:</strong></p><pre>" + $infra + "</pre><p><strong>Run URL:</strong> <a href=\"" + $url + "\">" + $url + "</a></p><p>Please fix the parameter mapping issues at your earliest convenience.</p><p>Best regards,<br>Your Automation Team</p>")}' \
88+
--arg body "$EMAIL_BODY" \
89+
'{subject: ("Bicep Parameter Validation Report - " + $name + " - Issues Detected"), body: $body}' \
8290
| curl -X POST "${LOGICAPP_URL}" \
8391
-H "Content-Type: application/json" \
8492
-d @- || echo "Failed to send notification"
@@ -87,18 +95,18 @@ jobs:
8795
if: github.event_name == 'schedule' && steps.result.outputs.status == 'success'
8896
env:
8997
LOGICAPP_URL: ${{ secrets.EMAILNOTIFICATION_LOGICAPP_URL_TA }}
90-
GITHUB_REPOSITORY: ${{ github.repository }}
91-
GITHUB_RUN_ID: ${{ github.run_id }}
9298
ACCELERATOR_NAME: ${{ env.accelerator_name }}
9399
run: |
94-
RUN_URL="https://github.com/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID}"
95-
INFRA_OUTPUT=$(sed 's/&/\&amp;/g; s/</\&lt;/g; s/>/\&gt;/g' infra_output.txt)
100+
if [ -f email_body.html ]; then
101+
EMAIL_BODY=$(cat email_body.html)
102+
else
103+
EMAIL_BODY="<p>Bicep parameter validation passed. Check the <a href=\"https://github.com/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID}\">workflow run</a> for details.</p>"
104+
fi
96105
97106
jq -n \
98107
--arg name "${ACCELERATOR_NAME}" \
99-
--arg infra "$INFRA_OUTPUT" \
100-
--arg url "$RUN_URL" \
101-
'{subject: ("Bicep Parameter Validation Report - " + $name + " - Passed"), body: ("<p>Dear Team,</p><p>The scheduled <strong>Bicep Parameter Validation</strong> for <strong>" + $name + "</strong> has completed successfully. All parameter mappings are valid.</p><p><strong>infra/ Results:</strong></p><pre>" + $infra + "</pre><p><strong>Run URL:</strong> <a href=\"" + $url + "\">" + $url + "</a></p><p>Best regards,<br>Your Automation Team</p>")}' \
108+
--arg body "$EMAIL_BODY" \
109+
'{subject: ("Bicep Parameter Validation Report - " + $name + " - Passed"), body: $body}' \
102110
| curl -X POST "${LOGICAPP_URL}" \
103111
-H "Content-Type: application/json" \
104112
-d @- || echo "Failed to send notification"

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ To deploy this solution accelerator, ensure you have access to an [Azure subscri
9595

9696
Check the [Azure Products by Region](https://azure.microsoft.com/en-us/explore/global-infrastructure/products-by-region/table) page and select a **region** where the following services are available: Azure OpenAI Service, Azure AI Search, and Azure Semantic Search.
9797

98-
Here are some example regions where the services are available: East US, East US2, Japan East, UK South, Sweden Central.
98+
Here are some example regions where the services are available: Australia East, East US2, France Central, Japan East, Norway East, Sweden Central, UK South, West US.
9999

100100
Pricing varies per region and usage, so it isn't possible to predict exact costs for your usage. The majority of the Azure resources used in this infrastructure are on usage-based pricing tiers. However, Azure Container Registry has a fixed cost per registry per day.
101101

docs/CustomizingAzdParameters.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
By default this template will use the environment name as the prefix to prevent naming collisions within Azure. The parameters below show the default values. You only need to run the statements below if you need to change the values.
44

5-
> To override any of the parameters, run `azd env set <PARAMETER_NAME> <VALUE>` before running `azd up`. On the first azd command, it will prompt you for the environment name. Be sure to choose 3-20 characters alphanumeric unique name.
5+
> To override any of the parameters, run `azd env set <PARAMETER_NAME> <VALUE>` before running `azd up`. On the first azd command, it will prompt you for the environment name. Be sure to choose 3-16 characters alphanumeric unique name.
66
77
## Parameters
88

@@ -23,7 +23,7 @@ By default this template will use the environment name as the prefix to prevent
2323
| `AZURE_ENV_REASONING_MODEL_NAME` | string | `o4-mini` | Specifies the name of the reasoning GPT model to be deployed. |
2424
| `AZURE_ENV_REASONING_MODEL_VERSION` | string | `2025-04-16` | Version of the reasoning GPT model to be used for deployment. |
2525
| `AZURE_ENV_REASONING_MODEL_CAPACITY` | int | `50` | Sets the reasoning GPT model capacity. |
26-
| `AZURE_ENV_IMAGETAG` | string | `latest_v3` | Docker image tag used for container deployments. |
26+
| `AZURE_ENV_IMAGE_TAG` | string | `latest_v4` | Docker image tag used for container deployments. |
2727
| `AZURE_ENV_ENABLE_TELEMETRY` | bool | `true` | Enables telemetry for monitoring and diagnostics. |
2828
| `AZURE_EXISTING_AIPROJECT_RESOURCE_ID` | string | `<Existing Workspace Id>` | Set this if you want to reuse an AI Foundry Project instead of creating a new one. |
2929
| `AZURE_ENV_EXISTING_LOG_ANALYTICS_WORKSPACE_RID` | string | Guide to get your [Existing Workspace ID](re-use-log-analytics.md) | Set this if you want to reuse an existing Log Analytics Workspace instead of creating a new one. |

docs/azure_app_service_auth_setup.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ This document provides step-by-step instructions to configure Azure App Registra
2626
2727
![Add Provider](./images/azure-app-service-auth-setup/AppAuthIdentityProviderAdd.png)
2828

29-
5. Accept the default values and click on `Add` button to go back to the previous page with the idenity provider added.
29+
5. Accept the default values and click on `Add` button to go back to the previous page with the identity provider added.
3030

3131
![Add Provider](./images/azure-app-service-auth-setup/AppAuthIdentityProviderAdded.png)
3232

docs/create_new_app_registration.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020

2121
![Redirect URL](images/azure-app-service-auth-setup/AddRedirectURL.png)
2222

23-
6. Click on `+ Add a platform`.
23+
6. Click on `+ Add redirect URI`.
2424

2525
![+ Add platform](images/azure-app-service-auth-setup/AddPlatform.png)
2626

-292 KB
Loading
-110 KB
Loading
-135 KB
Loading

infra/main.parameters.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,13 +48,13 @@
4848
"value": "${AZURE_ENV_REASONING_MODEL_CAPACITY}"
4949
},
5050
"backendContainerImageTag": {
51-
"value": "${AZURE_ENV_IMAGE_TAG}"
51+
"value": "${AZURE_ENV_IMAGE_TAG=latest_v4}"
5252
},
5353
"frontendContainerImageTag": {
54-
"value": "${AZURE_ENV_IMAGE_TAG}"
54+
"value": "${AZURE_ENV_IMAGE_TAG=latest_v4}"
5555
},
5656
"MCPContainerImageTag": {
57-
"value": "${AZURE_ENV_IMAGE_TAG}"
57+
"value": "${AZURE_ENV_IMAGE_TAG=latest_v4}"
5858
},
5959
"enableTelemetry": {
6060
"value": "${AZURE_ENV_ENABLE_TELEMETRY}"

0 commit comments

Comments
 (0)