Skip to content

Commit 6263563

Browse files
Merge pull request #483 from microsoft/exp-issues
fix: exp issues fix
2 parents b94068c + 3b7d717 commit 6263563

File tree

8 files changed

+65
-7
lines changed

8 files changed

+65
-7
lines changed

docs/CustomizingAzdParameters.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ By default this template will use the environment name as the prefix to prevent
1313
| `AZURE_ENV_OPENAI_LOCATION` | string | `<User selects during deployment>` | Specifies the region for OpenAI resource deployment. |
1414
| `AZURE_ENV_MODEL_DEPLOYMENT_TYPE` | string | `GlobalStandard` | Defines the deployment type for the AI model (e.g., Standard, GlobalStandard). |
1515
| `AZURE_ENV_MODEL_NAME` | string | `gpt-4o` | Specifies the name of the GPT model to be deployed. |
16-
| `AZURE_ENV_FOUNDRY_PROJECT_ID` | string | `<Existing Workspace Id>` | Set this if you want to reuse an AI Foundry Project instead of creating a new one. |
16+
| `AZURE_EXISTING_AI_PROJECT_RESOURCE_ID` | string | `<Existing Workspace Id>` | Set this if you want to reuse an AI Foundry Project instead of creating a new one. |
1717
| `AZURE_ENV_MODEL_VERSION` | string | `2024-08-06` | Version of the GPT model to be used for deployment. |
1818
| `AZURE_ENV_MODEL_CAPACITY` | int | `150` | Sets the GPT model capacity. |
1919
| `AZURE_ENV_IMAGETAG` | string | `latest` | Docker image tag used for container deployments. |

docs/DeploymentGuide.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,23 @@ By default, the `azd up` command uses the [`main.parameters.json`](../infra/main
6161

6262
For **production deployments**, the repository also provides [`main.waf.parameters.json`](../infra/main.waf.parameters.json), which applies a [Well-Architected Framework (WAF) aligned](https://learn.microsoft.com/en-us/azure/well-architected/) configuration. This option enables additional Azure best practices for reliability, security, cost optimization, operational excellence, and performance efficiency, such as:
6363

64+
**Prerequisite** — Enable the Microsoft.Compute/EncryptionAtHost feature for every subscription (and region, if required) where you plan to deploy VMs or VM scale sets with `encryptionAtHost: true`. Repeat the registration steps below for each target subscription (and for each region when applicable). This step is required for **WAF-aligned** (production) deployments.
65+
66+
Steps to enable the feature:
67+
1. Set the target subscription:
68+
Run: <code>az account set --subscription "&lt;YourSubscriptionId&gt;"</code>
69+
2. Register the feature (one time per subscription):
70+
Run: <code>az feature register --name EncryptionAtHost --namespace Microsoft.Compute</code>
71+
3. Wait until registration completes and shows "Registered":
72+
Run: <code>az feature show --name EncryptionAtHost --namespace Microsoft.Compute --query properties.state -o tsv</code>
73+
4. Refresh the provider (if required):
74+
Run: <code>az provider register --namespace Microsoft.Compute</code>
75+
5. Re-run the deployment after registration is complete.
76+
77+
Note: Feature registration can take several minutes. Ensure the feature is registered before attempting deployments that require encryptionAtHost.
78+
79+
Reference: Azure Host Encryption — https://learn.microsoft.com/azure/virtual-machines/disks-enable-host-based-encryption-portal?tabs=azure-cli
80+
6481
- Enhanced network security (e.g., Network protection with private endpoints)
6582
- Stricter access controls and managed identities
6683
- Logging, monitoring, and diagnostics enabled by default

docs/re-use-foundry-project.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ In the left-hand menu of the project blade:
3636
### 6. Set the Foundry Project Resource ID in Your Environment
3737
Run the following command in your terminal
3838
```bash
39-
azd env set AZURE_ENV_FOUNDRY_PROJECT_ID '<Existing Foundry Project Resource ID>'
39+
azd env set AZURE_EXISTING_AI_PROJECT_RESOURCE_ID '<Existing Foundry Project Resource ID>'
4040
```
4141
Replace `<Existing Foundry Project Resource ID>` with the value obtained from Step 5.
4242

infra/main.bicep

Lines changed: 23 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -232,7 +232,7 @@ module logAnalyticsWorkspace 'br/public:avm/res/operational-insights/workspace:0
232232
features: { enableLogAccessUsingOnlyResourcePermissions: true }
233233
diagnosticSettings: [{ useThisWorkspace: true }]
234234
// WAF aligned configuration for Redundancy
235-
dailyQuotaGb: enableRedundancy ? 10 : null //WAF recommendation: 10 GB per day is a good starting point for most workloads
235+
dailyQuotaGb: enableRedundancy ? 150 : null //WAF recommendation: 150 GB per day is a good starting point for most workloads
236236
replication: enableRedundancy
237237
? {
238238
enabled: true
@@ -799,6 +799,26 @@ module windowsVmDataCollectionRules 'br/public:avm/res/insights/data-collection-
799799
name: 'perfCounterDataSource60'
800800
}
801801
]
802+
windowsEventLogs: [
803+
{
804+
name: 'SecurityAuditEvents'
805+
streams: [
806+
'Microsoft-WindowsEvent'
807+
]
808+
eventLogName: 'Security'
809+
eventTypes: [
810+
{
811+
eventType: 'Audit Success'
812+
}
813+
{
814+
eventType: 'Audit Failure'
815+
}
816+
]
817+
xPathQueries: [
818+
'Security!*[System[(EventID=4624 or EventID=4625)]]'
819+
]
820+
}
821+
]
802822
}
803823
destinations: {
804824
logAnalytics: [
@@ -856,7 +876,7 @@ module virtualMachine 'br/public:avm/res/compute/virtual-machine:0.17.0' = if (e
856876
bypassPlatformSafetyChecksOnUserSchedule: true
857877
maintenanceConfigurationResourceId: maintenanceConfiguration!.outputs.resourceId
858878
enableAutomaticUpdates: true
859-
encryptionAtHost: false
879+
encryptionAtHost: true
860880
availabilityZone: virtualMachineAvailabilityZone
861881
proximityPlacementGroupResourceId: proximityPlacementGroup!.outputs.resourceId
862882
imageReference: {
@@ -1498,6 +1518,7 @@ module webSite 'modules/web-sites.bicep' = {
14981518
vnetImagePullEnabled: enablePrivateNetworking ? true : false
14991519
virtualNetworkSubnetId: enablePrivateNetworking ? virtualNetwork!.outputs.subnetResourceIds[4] : null
15001520
publicNetworkAccess: 'Enabled' // Always enabling the public network access for Web App
1521+
e2eEncryptionEnabled: true
15011522
}
15021523
}
15031524

infra/main.parameters.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
"value": "${AZURE_ENV_LOG_ANALYTICS_WORKSPACE_ID}"
3737
},
3838
"existingAiFoundryAiProjectResourceId": {
39-
"value": "${AZURE_ENV_FOUNDRY_PROJECT_ID}"
39+
"value": "${AZURE_EXISTING_AI_PROJECT_RESOURCE_ID}"
4040
}
4141
}
4242
}

infra/main.waf.parameters.json

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,26 @@
5151
"value": "${AZURE_ENV_LOG_ANALYTICS_WORKSPACE_ID}"
5252
},
5353
"existingAiFoundryAiProjectResourceId": {
54-
"value": "${AZURE_ENV_FOUNDRY_PROJECT_ID}"
54+
"value": "${AZURE_EXISTING_AI_PROJECT_RESOURCE_ID}"
55+
},
56+
"allowedFqdnList": {
57+
"value": [
58+
"mcr.microsoft.com",
59+
"openai.azure.com",
60+
"cognitiveservices.azure.com",
61+
"login.microsoftonline.com",
62+
"management.azure.com",
63+
"aiinfra.azure.com",
64+
"aiinfra.azure.net",
65+
"aiinfra.azureedge.net",
66+
"blob.core.windows.net",
67+
"database.windows.net",
68+
"vault.azure.net",
69+
"monitoring.azure.com",
70+
"dc.services.visualstudio.com",
71+
"azconfig.io",
72+
"azconfig.azure.net"
73+
]
5574
}
5675
}
5776
}

infra/modules/web-sites.bicep

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -207,6 +207,7 @@ resource app 'Microsoft.Web/sites@2024-04-01' = {
207207
vnetImagePullEnabled: vnetImagePullEnabled
208208
vnetRouteAllEnabled: vnetRouteAllEnabled
209209
scmSiteAlsoStopped: scmSiteAlsoStopped
210+
// Always enforce end to end encryption
210211
endToEndEncryptionEnabled: e2eEncryptionEnabled
211212
dnsConfiguration: dnsConfiguration
212213
autoGeneratedDomainNameLabelScope: autoGeneratedDomainNameLabelScope

infra/old/08-2025/main.parameters.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
"value": "${AZURE_ENV_MODEL_CAPACITY}"
4141
},
4242
"existingFoundryProjectResourceId": {
43-
"value": "${AZURE_ENV_FOUNDRY_PROJECT_ID}"
43+
"value": "${AZURE_EXISTING_AI_PROJECT_RESOURCE_ID}"
4444
},
4545
"imageTag": {
4646
"value": "${AZURE_ENV_IMAGE_TAG}"

0 commit comments

Comments
 (0)