Skip to content

Commit cbcc57d

Browse files
Merge pull request #274 from microsoft/dev
fix: merging dev changes to main
2 parents 0ae6f8e + d5c511c commit cbcc57d

23 files changed

+15139
-5705
lines changed

azure_custom.yaml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: modernize-your-code-solution-accelerator
2+
metadata:
3+
4+
5+
requiredVersions:
6+
azd: '>= 1.18.0'
7+
8+
parameters:
9+
azureAiServiceLocation:
10+
type: string
11+
default: japaneast
12+
13+
services:
14+
backend:
15+
project: ./src/backend
16+
host: containerapp
17+
language: python
18+
docker:
19+
path: Dockerfile
20+
remoteBuild: true
21+
frontend:
22+
project: ./src/frontend
23+
host: containerapp
24+
language: js
25+
docker:
26+
path: Dockerfile
27+
remoteBuild: true
28+
29+
infra:
30+
provider: bicep
31+
path: infra

docs/DeploymentGuide.md

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,18 @@ To change the azd parameters from the default values, follow the steps [here](..
188188
189189
5. Once the deployment has completed successfully, open the [Azure Portal](https://portal.azure.com/), go to the deployed resource group, find the container app with "frontend" in the name, and get the app URL from `Application URI`.
190190
191-
6. You can now delete the resources by running `azd down`, when you have finished trying out the application.
191+
6. You can now delete the resources by running `azd down`, when you have finished trying out the application.
192+
> **Note:** If you deployed with `enableRedundancy=true` and Log Analytics workspace replication is enabled, you must first disable replication before running `azd down` else resource group delete will fail. Follow the steps in [Handling Log Analytics Workspace Deletion with Replication Enabled](./LogAnalyticsReplicationDisable.md), wait until replication returns `false`, then run `azd down`.
193+
194+
### Deploy your local changes
195+
196+
To deploy your local changes rename the below files.
197+
198+
Rename `azure.yaml` to `azure_original.yaml` and `azure_custom.yaml` to `azure.yaml`.
199+
200+
Go to `infra` directory
201+
202+
Rename `main.bicep` to `main_original.bicep` and `main_custom.bicep` to `main.bicep`. Continue with the [deploying steps](https://github.com/microsoft/Modernize-your-code-solution-accelerator/blob/main/docs/DeploymentGuide.md#deploying-with-azd).
192203
193204
### 🛠️ Troubleshooting
194205
If you encounter any issues during the deployment process, please refer [troubleshooting](../docs/TroubleShootingSteps.md) document for detailed steps and solutions.
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# 🛠 Handling Log Analytics Workspace Deletion with Replication Enabled
2+
3+
If redundancy (replication) is enabled for your Log Analytics workspace, you must disable it before deleting the workspace or resource group. Otherwise, deletion will fail.
4+
5+
## ✅ Steps to Disable Replication Before Deletion
6+
Run the following Azure CLI command. Note: This operation may take about 5 minutes to complete.
7+
8+
```bash
9+
az resource update --ids "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.OperationalInsights/workspaces/{logAnalyticsName}" --set properties.replication.enabled=false
10+
```
11+
12+
Replace:
13+
- `{subscriptionId}` → Your Azure subscription ID
14+
- `{resourceGroupName}` → The name of your resource group
15+
- `{logAnalyticsName}` → The name of your Log Analytics workspace
16+
17+
Optional: Verify replication is disabled (should output `false`):
18+
```bash
19+
az resource show --ids "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.OperationalInsights/workspaces/{logAnalyticsName}" --query properties.replication.enabled -o tsv
20+
```
21+
22+
## ✅ After Disabling Replication
23+
You can safely delete:
24+
- The Log Analytics workspace (manual)
25+
- The resource group (manual), or
26+
- All provisioned resources via `azd down`
27+
28+
Return to: [Deployment Guide](./DeploymentGuide.md)

0 commit comments

Comments
 (0)