Skip to content

Commit a4d8310

Browse files
Update AI Foundry resource ID output logic
1 parent e1179c3 commit a4d8310

File tree

2 files changed

+44
-44
lines changed

2 files changed

+44
-44
lines changed

infra/main.bicep

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1249,7 +1249,7 @@ output AI_FOUNDRY_NAME string = aiFoundryAiProjectResourceName
12491249
output AI_FOUNDRY_RG_NAME string = aiFoundryAiServicesResourceGroupName
12501250

12511251
@description('Contains AI Foundry Resource ID')
1252-
output AI_FOUNDRY_RESOURCE_ID string = useExistingAiFoundryAiProject ? azureExistingAIProjectResourceId : aiFoundryAiServices!.outputs.resourceId
1252+
output AI_FOUNDRY_RESOURCE_ID string = useExistingAiFoundryAiProject ? existingAiFoundryAiServices.id : aiFoundryAiServices!.outputs.resourceId
12531253

12541254
@description('Contains AI Search Service Name')
12551255
output AI_SEARCH_SERVICE_NAME string = aiSearch.outputs.name

infra/main.json

Lines changed: 43 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@
55
"metadata": {
66
"_generator": {
77
"name": "bicep",
8-
"version": "0.37.4.10188",
9-
"templateHash": "15396608207760718220"
8+
"version": "0.38.33.27573",
9+
"templateHash": "17267100473060819897"
1010
},
1111
"name": "Document Generation Solution Accelerator",
1212
"description": "CSA CTO Gold Standard Solution Accelerator for Document Generation.\n"
@@ -454,7 +454,7 @@
454454
"logAnalyticsWorkspace": {
455455
"condition": "[and(parameters('enableMonitoring'), not(variables('useExistingLogAnalytics')))]",
456456
"type": "Microsoft.Resources/deployments",
457-
"apiVersion": "2022-09-01",
457+
"apiVersion": "2025-04-01",
458458
"name": "[take(format('avm.res.operational-insights.workspace.{0}', variables('logAnalyticsWorkspaceResourceName')), 64)]",
459459
"properties": {
460460
"expressionEvaluationOptions": {
@@ -3560,7 +3560,7 @@
35603560
"applicationInsights": {
35613561
"condition": "[parameters('enableMonitoring')]",
35623562
"type": "Microsoft.Resources/deployments",
3563-
"apiVersion": "2022-09-01",
3563+
"apiVersion": "2025-04-01",
35643564
"name": "[take(format('avm.res.insights.component.{0}', variables('applicationInsightsResourceName')), 64)]",
35653565
"properties": {
35663566
"expressionEvaluationOptions": {
@@ -4296,7 +4296,7 @@
42964296
},
42974297
"userAssignedIdentity": {
42984298
"type": "Microsoft.Resources/deployments",
4299-
"apiVersion": "2022-09-01",
4299+
"apiVersion": "2025-04-01",
43004300
"name": "[take(format('avm.res.managed-identity.user-assigned-identity.{0}', variables('userAssignedIdentityResourceName')), 64)]",
43014301
"properties": {
43024302
"expressionEvaluationOptions": {
@@ -4779,7 +4779,7 @@
47794779
"virtualNetwork": {
47804780
"condition": "[parameters('enablePrivateNetworking')]",
47814781
"type": "Microsoft.Resources/deployments",
4782-
"apiVersion": "2022-09-01",
4782+
"apiVersion": "2025-04-01",
47834783
"name": "[take(format('module.virtualNetwork.{0}', variables('solutionSuffix')), 64)]",
47844784
"properties": {
47854785
"expressionEvaluationOptions": {
@@ -4816,8 +4816,8 @@
48164816
"metadata": {
48174817
"_generator": {
48184818
"name": "bicep",
4819-
"version": "0.37.4.10188",
4820-
"templateHash": "15908341678380884075"
4819+
"version": "0.38.33.27573",
4820+
"templateHash": "1734974014097019118"
48214821
}
48224822
},
48234823
"definitions": {
@@ -5210,7 +5210,7 @@
52105210
},
52115211
"condition": "[not(empty(tryGet(parameters('subnets')[copyIndex()], 'networkSecurityGroup')))]",
52125212
"type": "Microsoft.Resources/deployments",
5213-
"apiVersion": "2022-09-01",
5213+
"apiVersion": "2025-04-01",
52145214
"name": "[take(format('avm.res.network.network-security-group.{0}.{1}', tryGet(parameters('subnets')[copyIndex()], 'networkSecurityGroup', 'name'), parameters('resourceSuffix')), 64)]",
52155215
"properties": {
52165216
"expressionEvaluationOptions": {
@@ -5862,7 +5862,7 @@
58625862
},
58635863
"virtualNetwork": {
58645864
"type": "Microsoft.Resources/deployments",
5865-
"apiVersion": "2022-09-01",
5865+
"apiVersion": "2025-04-01",
58665866
"name": "[take(format('avm.res.network.virtual-network.{0}', parameters('name')), 64)]",
58675867
"properties": {
58685868
"expressionEvaluationOptions": {
@@ -7589,7 +7589,7 @@
75897589
"bastionHost": {
75907590
"condition": "[parameters('enablePrivateNetworking')]",
75917591
"type": "Microsoft.Resources/deployments",
7592-
"apiVersion": "2022-09-01",
7592+
"apiVersion": "2025-04-01",
75937593
"name": "[take(format('avm.res.network.bastion-host.{0}', variables('bastionHostName')), 64)]",
75947594
"properties": {
75957595
"expressionEvaluationOptions": {
@@ -8908,7 +8908,7 @@
89088908
"jumpboxVM": {
89098909
"condition": "[parameters('enablePrivateNetworking')]",
89108910
"type": "Microsoft.Resources/deployments",
8911-
"apiVersion": "2022-09-01",
8911+
"apiVersion": "2025-04-01",
89128912
"name": "[take(format('avm.res.compute.virtual-machine.{0}', variables('jumpboxVmName')), 64)]",
89138913
"properties": {
89148914
"expressionEvaluationOptions": {
@@ -17258,7 +17258,7 @@
1725817258
},
1725917259
"condition": "[parameters('enablePrivateNetworking')]",
1726017260
"type": "Microsoft.Resources/deployments",
17261-
"apiVersion": "2022-09-01",
17261+
"apiVersion": "2025-04-01",
1726217262
"name": "[format('avm.res.network.private-dns-zone.{0}', split(variables('privateDnsZones')[copyIndex()], '.')[1])]",
1726317263
"properties": {
1726417264
"expressionEvaluationOptions": {
@@ -20426,7 +20426,7 @@
2042620426
"existingAiFoundryAiServicesDeployments": {
2042720427
"condition": "[variables('useExistingAiFoundryAiProject')]",
2042820428
"type": "Microsoft.Resources/deployments",
20429-
"apiVersion": "2022-09-01",
20429+
"apiVersion": "2025-04-01",
2043020430
"name": "[take(format('module.ai-services-model-deployments.{0}', variables('aiFoundryAiServicesResourceName')), 64)]",
2043120431
"subscriptionId": "[variables('aiFoundryAiServicesSubscriptionId')]",
2043220432
"resourceGroup": "[variables('aiFoundryAiServicesResourceGroupName')]",
@@ -20475,8 +20475,8 @@
2047520475
"metadata": {
2047620476
"_generator": {
2047720477
"name": "bicep",
20478-
"version": "0.37.4.10188",
20479-
"templateHash": "2655660447689660274"
20478+
"version": "0.38.33.27573",
20479+
"templateHash": "2501367807605442530"
2048020480
}
2048120481
},
2048220482
"definitions": {
@@ -20805,7 +20805,7 @@
2080520805
"aiFoundryAiServices": {
2080620806
"condition": "[not(variables('useExistingAiFoundryAiProject'))]",
2080720807
"type": "Microsoft.Resources/deployments",
20808-
"apiVersion": "2022-09-01",
20808+
"apiVersion": "2025-04-01",
2080920809
"name": "[take(format('avm.res.cognitive-services.account.{0}', variables('aiFoundryAiServicesResourceName')), 64)]",
2081020810
"properties": {
2081120811
"expressionEvaluationOptions": {
@@ -23418,9 +23418,9 @@
2341823418
}
2341923419
},
2342023420
"dependsOn": [
23421-
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').cognitiveServices)]",
23422-
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').openAI)]",
2342323421
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').aiServices)]",
23422+
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').openAI)]",
23423+
"[format('avmPrivateDnsZones[{0}]', variables('dnsZoneIndex').cognitiveServices)]",
2342423424
"logAnalyticsWorkspace",
2342523425
"userAssignedIdentity",
2342623426
"virtualNetwork"
@@ -23429,7 +23429,7 @@
2342923429
"aiFoundryAiServicesProject": {
2343023430
"condition": "[not(variables('useExistingAiFoundryAiProject'))]",
2343123431
"type": "Microsoft.Resources/deployments",
23432-
"apiVersion": "2022-09-01",
23432+
"apiVersion": "2025-04-01",
2343323433
"name": "[take(format('module.ai-project.{0}', variables('aiFoundryAiProjectResourceName')), 64)]",
2343423434
"properties": {
2343523435
"expressionEvaluationOptions": {
@@ -23462,8 +23462,8 @@
2346223462
"metadata": {
2346323463
"_generator": {
2346423464
"name": "bicep",
23465-
"version": "0.37.4.10188",
23466-
"templateHash": "16867891653751120909"
23465+
"version": "0.38.33.27573",
23466+
"templateHash": "107641519342838452"
2346723467
}
2346823468
},
2346923469
"parameters": {
@@ -23574,7 +23574,7 @@
2357423574
"searchServiceToExistingAiServicesRoleAssignment": {
2357523575
"condition": "[variables('useExistingAiFoundryAiProject')]",
2357623576
"type": "Microsoft.Resources/deployments",
23577-
"apiVersion": "2022-09-01",
23577+
"apiVersion": "2025-04-01",
2357823578
"name": "searchToExistingAiServices-roleAssignment",
2357923579
"subscriptionId": "[variables('aiFoundryAiServicesSubscriptionId')]",
2358023580
"resourceGroup": "[variables('aiFoundryAiServicesResourceGroupName')]",
@@ -23600,8 +23600,8 @@
2360023600
"metadata": {
2360123601
"_generator": {
2360223602
"name": "bicep",
23603-
"version": "0.37.4.10188",
23604-
"templateHash": "3644919950024112374"
23603+
"version": "0.38.33.27573",
23604+
"templateHash": "9717690292313179013"
2360523605
}
2360623606
},
2360723607
"parameters": {
@@ -23650,7 +23650,7 @@
2365023650
},
2365123651
"aiSearch": {
2365223652
"type": "Microsoft.Resources/deployments",
23653-
"apiVersion": "2022-09-01",
23653+
"apiVersion": "2025-04-01",
2365423654
"name": "[take(format('avm.res.search.search-service.{0}', variables('aiSearchName')), 64)]",
2365523655
"properties": {
2365623656
"expressionEvaluationOptions": {
@@ -26026,7 +26026,7 @@
2602626026
"existing_AIProject_SearchConnectionModule": {
2602726027
"condition": "[variables('useExistingAiFoundryAiProject')]",
2602826028
"type": "Microsoft.Resources/deployments",
26029-
"apiVersion": "2022-09-01",
26029+
"apiVersion": "2025-04-01",
2603026030
"name": "aiProjectSearchConnectionDeployment",
2603126031
"subscriptionId": "[variables('aiFoundryAiServicesSubscriptionId')]",
2603226032
"resourceGroup": "[variables('aiFoundryAiServicesResourceGroupName')]",
@@ -26061,8 +26061,8 @@
2606126061
"metadata": {
2606226062
"_generator": {
2606326063
"name": "bicep",
26064-
"version": "0.37.4.10188",
26065-
"templateHash": "6038840175458269917"
26064+
"version": "0.38.33.27573",
26065+
"templateHash": "11311597701635556530"
2606626066
}
2606726067
},
2606826068
"parameters": {
@@ -26129,7 +26129,7 @@
2612926129
},
2613026130
"storageAccount": {
2613126131
"type": "Microsoft.Resources/deployments",
26132-
"apiVersion": "2022-09-01",
26132+
"apiVersion": "2025-04-01",
2613326133
"name": "[take(format('avm.res.storage.storage-account.{0}', variables('storageAccountName')), 64)]",
2613426134
"properties": {
2613526135
"expressionEvaluationOptions": {
@@ -31901,7 +31901,7 @@
3190131901
},
3190231902
"cosmosDB": {
3190331903
"type": "Microsoft.Resources/deployments",
31904-
"apiVersion": "2022-09-01",
31904+
"apiVersion": "2025-04-01",
3190531905
"name": "[take(format('avm.res.document-db.database-account.{0}', variables('cosmosDBResourceName')), 64)]",
3190631906
"properties": {
3190731907
"expressionEvaluationOptions": {
@@ -35739,7 +35739,7 @@
3573935739
},
3574035740
"keyvault": {
3574135741
"type": "Microsoft.Resources/deployments",
35742-
"apiVersion": "2022-09-01",
35742+
"apiVersion": "2025-04-01",
3574335743
"name": "[take(format('avm.res.key-vault.vault.{0}', variables('keyVaultName')), 64)]",
3574435744
"properties": {
3574535745
"expressionEvaluationOptions": {
@@ -35812,15 +35812,15 @@
3581235812
},
3581335813
{
3581435814
"name": "ADLS-ACCOUNT-KEY",
35815-
"value": "[listOutputsWithSecureValues('storageAccount', '2022-09-01').primaryAccessKey]"
35815+
"value": "[listOutputsWithSecureValues('storageAccount', '2025-04-01').primaryAccessKey]"
3581635816
},
3581735817
{
3581835818
"name": "AZURE-COSMOSDB-ACCOUNT",
3581935819
"value": "[reference('cosmosDB').outputs.name.value]"
3582035820
},
3582135821
{
3582235822
"name": "AZURE-COSMOSDB-ACCOUNT-KEY",
35823-
"value": "[listOutputsWithSecureValues('cosmosDB', '2022-09-01').primaryReadWriteKey]"
35823+
"value": "[listOutputsWithSecureValues('cosmosDB', '2025-04-01').primaryReadWriteKey]"
3582435824
},
3582535825
{
3582635826
"name": "AZURE-COSMOSDB-DATABASE",
@@ -39018,7 +39018,7 @@
3901839018
},
3901939019
"webServerFarm": {
3902039020
"type": "Microsoft.Resources/deployments",
39021-
"apiVersion": "2022-09-01",
39021+
"apiVersion": "2025-04-01",
3902239022
"name": "[take(format('avm.res.web.serverfarm.{0}', variables('webServerFarmResourceName')), 64)]",
3902339023
"resourceGroup": "[resourceGroup().name]",
3902439024
"properties": {
@@ -39590,7 +39590,7 @@
3959039590
},
3959139591
"webSite": {
3959239592
"type": "Microsoft.Resources/deployments",
39593-
"apiVersion": "2022-09-01",
39593+
"apiVersion": "2025-04-01",
3959439594
"name": "[take(format('module.web-sites.{0}', variables('webSiteResourceName')), 64)]",
3959539595
"properties": {
3959639596
"expressionEvaluationOptions": {
@@ -39647,8 +39647,8 @@
3964739647
"metadata": {
3964839648
"_generator": {
3964939649
"name": "bicep",
39650-
"version": "0.37.4.10188",
39651-
"templateHash": "4085174230724704576"
39650+
"version": "0.38.33.27573",
39651+
"templateHash": "6605577820404885863"
3965239652
}
3965339653
},
3965439654
"definitions": {
@@ -40633,7 +40633,7 @@
4063340633
"count": "[length(coalesce(parameters('configs'), createArray()))]"
4063440634
},
4063540635
"type": "Microsoft.Resources/deployments",
40636-
"apiVersion": "2022-09-01",
40636+
"apiVersion": "2025-04-01",
4063740637
"name": "[format('{0}-Site-Config-{1}', uniqueString(deployment().name, parameters('location')), copyIndex())]",
4063840638
"properties": {
4063940639
"expressionEvaluationOptions": {
@@ -40671,8 +40671,8 @@
4067140671
"metadata": {
4067240672
"_generator": {
4067340673
"name": "bicep",
40674-
"version": "0.37.4.10188",
40675-
"templateHash": "3088317872832633980"
40674+
"version": "0.38.33.27573",
40675+
"templateHash": "6347509742103743399"
4067640676
},
4067740677
"name": "Site App Settings",
4067840678
"description": "This module deploys a Site App Setting."
@@ -40827,7 +40827,7 @@
4082740827
"count": "[length(coalesce(parameters('privateEndpoints'), createArray()))]"
4082840828
},
4082940829
"type": "Microsoft.Resources/deployments",
40830-
"apiVersion": "2022-09-01",
40830+
"apiVersion": "2025-04-01",
4083140831
"name": "[format('{0}-app-PrivateEndpoint-{1}', uniqueString(deployment().name, parameters('location')), copyIndex())]",
4083240832
"subscriptionId": "[split(coalesce(tryGet(coalesce(parameters('privateEndpoints'), createArray())[copyIndex()], 'resourceGroupResourceId'), resourceGroup().id), '/')[2]]",
4083340833
"resourceGroup": "[split(coalesce(tryGet(coalesce(parameters('privateEndpoints'), createArray())[copyIndex()], 'resourceGroupResourceId'), resourceGroup().id), '/')[4]]",
@@ -41714,7 +41714,7 @@
4171441714
"metadata": {
4171541715
"description": "Contains AI Foundry Resource ID"
4171641716
},
41717-
"value": "[if(variables('useExistingAiFoundryAiProject'), parameters('azureExistingAIProjectResourceId'), reference('aiFoundryAiServices').outputs.resourceId.value)]"
41717+
"value": "[if(variables('useExistingAiFoundryAiProject'), extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', variables('aiFoundryAiServicesSubscriptionId'), variables('aiFoundryAiServicesResourceGroupName')), 'Microsoft.CognitiveServices/accounts', variables('aiFoundryAiServicesResourceName')), reference('aiFoundryAiServices').outputs.resourceId.value)]"
4171841718
},
4171941719
"AI_SEARCH_SERVICE_NAME": {
4172041720
"type": "string",

0 commit comments

Comments
 (0)