Skip to content

Commit 2d5ad9e

Browse files
Merge pull request #359 from microsoft/prdc_sql_tool_removal
feat: Fabric Data Agent as tool & user assertion token based Auth for Workshop mode
2 parents 1bdb83b + 802a99a commit 2d5ad9e

17 files changed

Lines changed: 1588 additions & 165 deletions

infra/main.bicep

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,8 +92,19 @@ param azureEnvOnly bool = false
9292

9393
@description('Enable chat history.')
9494
param useChatHistoryEnabled bool = true
95+
96+
@description('The primary title displayed in the header of the web app (bold text).')
97+
param appTitlePrimary string = 'Contoso'
98+
99+
@description('The secondary title displayed in the header of the web app (lighter text).')
100+
param appTitleSecondary string = '| Unified Data Analysis Agents'
101+
95102
var useChatHistoryEnabledSetting = useChatHistoryEnabled ? 'True' : 'False'
96103

104+
@description('Enable user access token forwarding to the API.')
105+
param useUserAccessToken bool = false
106+
var useUserAccessTokenSetting = useUserAccessToken ? 'True' : 'False'
107+
97108
// If isWorkshop is false, always deploy; if isWorkshop is true, respect deployApp
98109
var shouldDeployApp = !isWorkshop || deployApp
99110

@@ -270,6 +281,7 @@ module backend_docker 'deploy_backend_docker.bicep' = if (shouldDeployApp && bac
270281
SOLUTION_NAME: solutionSuffix
271282
IS_WORKSHOP: isWorkshop ? 'True' : 'False'
272283
AZURE_ENV_ONLY: azureEnvOnly ? 'True' : 'False'
284+
USE_USER_ACCESS_TOKEN: useUserAccessTokenSetting
273285
APP_ENV: 'Prod'
274286
AZURE_BASIC_LOGGING_LEVEL: 'INFO'
275287
AZURE_PACKAGE_LOGGING_LEVEL: 'WARNING'
@@ -351,6 +363,8 @@ module frontend_docker 'deploy_frontend_docker.bicep' = if (shouldDeployApp) {
351363
APP_API_BASE_URL: backendRuntimeStack == 'python' ? backend_docker!.outputs.appUrl : backend_csapi_docker!.outputs.appUrl
352364
CHAT_LANDING_TEXT: landingText
353365
IS_WORKSHOP: isWorkshop ? 'True' : 'False'
366+
APP_TITLE_PRIMARY: appTitlePrimary
367+
APP_TITLE_SECONDARY: appTitleSecondary
354368
}
355369
}
356370
scope: resourceGroup(resourceGroup().name)
@@ -464,3 +478,6 @@ output AZURE_ENV_DEPLOY_APP bool = deployApp
464478

465479
@description('Flag indicating Azure-only mode (no Fabric)')
466480
output AZURE_ENV_ONLY bool = azureEnvOnly
481+
482+
@description('Flag indicating whether user access token forwarding is enabled')
483+
output USE_USER_ACCESS_TOKEN string = useUserAccessTokenSetting

infra/main.json

Lines changed: 34 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"_generator": {
66
"name": "bicep",
77
"version": "0.42.1.51946",
8-
"templateHash": "2129642045338742014"
8+
"templateHash": "14768825107451790909"
99
}
1010
},
1111
"parameters": {
@@ -178,6 +178,27 @@
178178
"description": "Enable chat history."
179179
}
180180
},
181+
"appTitlePrimary": {
182+
"type": "string",
183+
"defaultValue": "Contoso",
184+
"metadata": {
185+
"description": "The primary title displayed in the header of the web app (bold text)."
186+
}
187+
},
188+
"appTitleSecondary": {
189+
"type": "string",
190+
"defaultValue": "| Unified Data Analysis Agents",
191+
"metadata": {
192+
"description": "The secondary title displayed in the header of the web app (lighter text)."
193+
}
194+
},
195+
"useUserAccessToken": {
196+
"type": "bool",
197+
"defaultValue": false,
198+
"metadata": {
199+
"description": "Enable user access token forwarding to the API."
200+
}
201+
},
181202
"AZURE_LOCATION": {
182203
"type": "string",
183204
"defaultValue": ""
@@ -457,6 +478,7 @@
457478
},
458479
"abbrs": "[variables('$fxv#0')]",
459480
"useChatHistoryEnabledSetting": "[if(parameters('useChatHistoryEnabled'), 'True', 'False')]",
481+
"useUserAccessTokenSetting": "[if(parameters('useUserAccessToken'), 'True', 'False')]",
460482
"shouldDeployApp": "[or(not(parameters('isWorkshop')), parameters('deployApp'))]",
461483
"solutionLocation": "[if(empty(parameters('AZURE_LOCATION')), resourceGroup().location, parameters('AZURE_LOCATION'))]",
462484
"solutionSuffix": "[toLower(trim(replace(replace(replace(replace(replace(replace(format('{0}{1}', parameters('environmentName'), parameters('solutionUniqueText')), '-', ''), '_', ''), '.', ''), '/', ''), ' ', ''), '*', '')))]",
@@ -2919,6 +2941,7 @@
29192941
"SOLUTION_NAME": "[variables('solutionSuffix')]",
29202942
"IS_WORKSHOP": "[if(parameters('isWorkshop'), 'True', 'False')]",
29212943
"AZURE_ENV_ONLY": "[if(parameters('azureEnvOnly'), 'True', 'False')]",
2944+
"USE_USER_ACCESS_TOKEN": "[variables('useUserAccessTokenSetting')]",
29222945
"APP_ENV": "Prod",
29232946
"AZURE_BASIC_LOGGING_LEVEL": "INFO",
29242947
"AZURE_PACKAGE_LOGGING_LEVEL": "WARNING",
@@ -4538,7 +4561,9 @@
45384561
"value": {
45394562
"APP_API_BASE_URL": "[if(equals(parameters('backendRuntimeStack'), 'python'), reference(extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.Resources/deployments', 'deploy_backend_docker'), '2025-04-01').outputs.appUrl.value, reference(extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.Resources/deployments', 'deploy_backend_csapi_docker'), '2025-04-01').outputs.appUrl.value)]",
45404563
"CHAT_LANDING_TEXT": "[variables('landingText')]",
4541-
"IS_WORKSHOP": "[if(parameters('isWorkshop'), 'True', 'False')]"
4564+
"IS_WORKSHOP": "[if(parameters('isWorkshop'), 'True', 'False')]",
4565+
"APP_TITLE_PRIMARY": "[parameters('appTitlePrimary')]",
4566+
"APP_TITLE_SECONDARY": "[parameters('appTitleSecondary')]"
45424567
}
45434568
}
45444569
},
@@ -5085,6 +5110,13 @@
50855110
"description": "Flag indicating Azure-only mode (no Fabric)"
50865111
},
50875112
"value": "[parameters('azureEnvOnly')]"
5113+
},
5114+
"USE_USER_ACCESS_TOKEN": {
5115+
"type": "string",
5116+
"metadata": {
5117+
"description": "Flag indicating whether user access token forwarding is enabled"
5118+
},
5119+
"value": "[variables('useUserAccessTokenSetting')]"
50885120
}
50895121
}
50905122
}

0 commit comments

Comments
 (0)