Skip to content

Commit eed13d1

Browse files
Agents/setup/allowed regions (#208)
* Allowed region * Allowed region with policy * Allowed region with policy * Allowed region with policy * Allowed region, revert policy * Allowed region * Update Readme * Nit space
1 parent b3a874b commit eed13d1

File tree

3 files changed

+46
-8
lines changed

3 files changed

+46
-8
lines changed

scenarios/Agents/setup/network-secured-agent/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,4 +218,4 @@ Storage: privatelink.blob.core.windows.net
218218
- [RBAC Documentation](https://learn.microsoft.com/en-us/azure/role-based-access-control/)
219219
- [Network Security Best Practices](https://learn.microsoft.com/en-us/azure/security/fundamentals/network-best-practices)
220220

221-
`Tags: `
221+
`Tags: `

scenarios/Agents/setup/network-secured-agent/azuredeploy.json

Lines changed: 24 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"_generator": {
66
"name": "bicep",
77
"version": "0.33.93.31351",
8-
"templateHash": "15839381951477066016"
8+
"templateHash": "2121999007807216050"
99
}
1010
},
1111
"parameters": {
@@ -65,11 +65,32 @@
6565
"description": "Description of your Azure AI resource displayed in AI studio"
6666
}
6767
},
68-
"location": {
68+
"resourceGroupLocation": {
6969
"type": "string",
7070
"defaultValue": "[resourceGroup().location]",
7171
"metadata": {
72-
"description": "Azure region used for the deployment of all resources."
72+
"description": "Resource group location"
73+
}
74+
},
75+
"location": {
76+
"type": "string",
77+
"defaultValue": "[parameters('resourceGroupLocation')]",
78+
"allowedValues": [
79+
"australiaeast",
80+
"eastus",
81+
"eastus2",
82+
"francecentral",
83+
"japaneast",
84+
"norwayeast",
85+
"southindia",
86+
"swedencentral",
87+
"uaenorth",
88+
"uksouth",
89+
"westus",
90+
"westus3"
91+
],
92+
"metadata": {
93+
"description": "Location for all resources."
7394
}
7495
},
7596
"tags": {

scenarios/Agents/setup/network-secured-agent/main.bicep

Lines changed: 21 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,25 @@ param defaultAiProjectFriendlyName string = 'Agents Project resource'
5555
@description('Description of your Azure AI resource displayed in AI studio')
5656
param defaultAiProjectDescription string = 'This is an example AI Project resource for use in Azure AI Studio.'
5757

58-
@description('Azure region used for the deployment of all resources.')
59-
param location string = resourceGroup().location
58+
@description('Resource group location')
59+
param resourceGroupLocation string = resourceGroup().location
60+
61+
@allowed([
62+
'australiaeast'
63+
'eastus'
64+
'eastus2'
65+
'francecentral'
66+
'japaneast'
67+
'norwayeast'
68+
'southindia'
69+
'swedencentral'
70+
'uaenorth'
71+
'uksouth'
72+
'westus'
73+
'westus3'
74+
])
75+
@description('Location for all resources.')
76+
param location string = resourceGroupLocation
6077

6178
@description('Set of tags to apply to all resources.')
6279
param tags object = {}
@@ -109,6 +126,8 @@ param aiSearchServiceName string = ''
109126
param userAssignedIdentityDefaultName string = 'secured-agents-identity-${uniqueSuffix}'
110127
var uaiName = (userAssignedIdentityOverride == '') ? userAssignedIdentityDefaultName : userAssignedIdentityOverride
111128

129+
130+
112131
module identity 'modules-network-secured/network-secured-identity.bicep' = {
113132
name: '${name}-${uniqueSuffix}--identity'
114133
params: {
@@ -118,8 +137,6 @@ module identity 'modules-network-secured/network-secured-identity.bicep' = {
118137
}
119138
}
120139

121-
122-
123140
/* ---------------------------------- Create AI Assistant Dependent Resources ---------------------------------- */
124141

125142
// var storageName = empty(aiStorageAccountName) ? '${defaultStorageName}${uniqueSuffix}' : aiStorageAccountName

0 commit comments

Comments
 (0)