|
5 | 5 | "_generator": {
|
6 | 6 | "name": "bicep",
|
7 | 7 | "version": "0.34.44.8038",
|
8 |
| - "templateHash": "11969070936051168983" |
| 8 | + "templateHash": "1028263065130624134" |
9 | 9 | }
|
10 | 10 | },
|
11 | 11 | "parameters": {
|
|
1961 | 1961 | "applicationInsightsId": {
|
1962 | 1962 | "value": "[reference(extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.Resources/deployments', 'deploy_ai_foundry'), '2022-09-01').outputs.applicationInsightsId.value]"
|
1963 | 1963 | },
|
| 1964 | + "azureOpenAIKey": { |
| 1965 | + "reference": { |
| 1966 | + "keyVault": { |
| 1967 | + "id": "[extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.KeyVault/vaults', reference(extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.Resources/deployments', 'deploy_ai_foundry'), '2022-09-01').outputs.keyvaultName.value)]" |
| 1968 | + }, |
| 1969 | + "secretName": "AZURE-OPENAI-KEY" |
| 1970 | + } |
| 1971 | + }, |
| 1972 | + "azureAiProjectConnString": { |
| 1973 | + "reference": { |
| 1974 | + "keyVault": { |
| 1975 | + "id": "[extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.KeyVault/vaults', reference(extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.Resources/deployments', 'deploy_ai_foundry'), '2022-09-01').outputs.keyvaultName.value)]" |
| 1976 | + }, |
| 1977 | + "secretName": "AZURE-AI-PROJECT-CONN-STRING" |
| 1978 | + } |
| 1979 | + }, |
| 1980 | + "azureSearchAdminKey": { |
| 1981 | + "reference": { |
| 1982 | + "keyVault": { |
| 1983 | + "id": "[extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.KeyVault/vaults', reference(extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.Resources/deployments', 'deploy_ai_foundry'), '2022-09-01').outputs.keyvaultName.value)]" |
| 1984 | + }, |
| 1985 | + "secretName": "AZURE-SEARCH-KEY" |
| 1986 | + } |
| 1987 | + }, |
1964 | 1988 | "solutionName": {
|
1965 | 1989 | "value": "[variables('solutionPrefix')]"
|
1966 | 1990 | },
|
1967 | 1991 | "userassignedIdentityId": {
|
1968 | 1992 | "value": "[reference(extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.Resources/deployments', 'deploy_managed_identity'), '2022-09-01').outputs.managedIdentityBackendAppOutput.value.id]"
|
1969 | 1993 | },
|
1970 |
| - "keyVaultName": { |
1971 |
| - "value": "[reference(extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.Resources/deployments', 'deploy_ai_foundry'), '2022-09-01').outputs.keyvaultName.value]" |
1972 |
| - }, |
1973 | 1994 | "appSettings": {
|
1974 | 1995 | "value": {
|
1975 | 1996 | "AZURE_OPEN_AI_DEPLOYMENT_MODEL": "[parameters('gptModelName')]",
|
1976 | 1997 | "AZURE_OPEN_AI_ENDPOINT": "[reference(extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.Resources/deployments', 'deploy_ai_foundry'), '2022-09-01').outputs.aiServicesTarget.value]",
|
1977 | 1998 | "AZURE_OPENAI_API_VERSION": "[variables('azureOpenAIApiVersion')]",
|
1978 | 1999 | "AZURE_OPENAI_RESOURCE": "[reference(extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.Resources/deployments', 'deploy_ai_foundry'), '2022-09-01').outputs.aiServicesName.value]",
|
1979 |
| - "AZURE_OPENAI_API_KEY": "AZURE-OPENAI-KEY", |
1980 |
| - "AZURE_KEY_VAULT_URL": "[reference(extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.Resources/deployments', 'deploy_keyvault'), '2022-09-01').outputs.keyvaultUri.value]", |
1981 | 2000 | "USE_CHAT_HISTORY_ENABLED": "True",
|
1982 | 2001 | "AZURE_COSMOSDB_ACCOUNT": "[reference(extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.Resources/deployments', 'deploy_cosmos_db'), '2022-09-01').outputs.cosmosAccountName.value]",
|
1983 | 2002 | "AZURE_COSMOSDB_CONVERSATIONS_CONTAINER": "[reference(extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.Resources/deployments', 'deploy_cosmos_db'), '2022-09-01').outputs.cosmosContainerName.value]",
|
|
1990 | 2009 | "OPENAI_API_VERSION": "[variables('azureOpenAIApiVersion')]",
|
1991 | 2010 | "AZURE_AI_SEARCH_ENDPOINT": "[reference(extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.Resources/deployments', 'deploy_ai_foundry'), '2022-09-01').outputs.aiSearchTarget.value]",
|
1992 | 2011 | "AZURE_AI_SEARCH_INDEX": "call_transcripts_index",
|
1993 |
| - "AZURE_AI_SEARCH_API_KEY": "AZURE-SEARCH-KEY", |
1994 | 2012 | "USE_AI_PROJECT_CLIENT": "False",
|
1995 |
| - "AZURE_AI_PROJECT_CONN_STRING": "AZURE-AI-PROJECT-CONN-STRING", |
1996 | 2013 | "DISPLAY_CHART_DEFAULT": "True"
|
1997 | 2014 | }
|
1998 | 2015 | }
|
|
2004 | 2021 | "_generator": {
|
2005 | 2022 | "name": "bicep",
|
2006 | 2023 | "version": "0.34.44.8038",
|
2007 |
| - "templateHash": "3648197818087330444" |
| 2024 | + "templateHash": "445807380408189331" |
2008 | 2025 | }
|
2009 | 2026 | },
|
2010 | 2027 | "parameters": {
|
|
2024 | 2041 | "appServicePlanId": {
|
2025 | 2042 | "type": "string"
|
2026 | 2043 | },
|
2027 |
| - "userassignedIdentityId": { |
2028 |
| - "type": "string" |
| 2044 | + "azureOpenAIKey": { |
| 2045 | + "type": "securestring" |
2029 | 2046 | },
|
2030 |
| - "keyVaultName": { |
| 2047 | + "azureAiProjectConnString": { |
| 2048 | + "type": "securestring" |
| 2049 | + }, |
| 2050 | + "azureSearchAdminKey": { |
| 2051 | + "type": "securestring" |
| 2052 | + }, |
| 2053 | + "userassignedIdentityId": { |
2031 | 2054 | "type": "string"
|
2032 | 2055 | }
|
2033 | 2056 | },
|
2034 | 2057 | "variables": {
|
2035 | 2058 | "imageName": "[format('DOCKER|kmcontainerreg.azurecr.io/km-api:{0}', parameters('imageTag'))]",
|
2036 | 2059 | "name": "[format('{0}-api', parameters('solutionName'))]",
|
2037 |
| - "reactAppLayoutConfig": "{\r\n \"appConfig\": {\r\n \"THREE_COLUMN\": {\r\n \"DASHBOARD\": 50,\r\n \"CHAT\": 33,\r\n \"CHATHISTORY\": 17\r\n },\r\n \"TWO_COLUMN\": {\r\n \"DASHBOARD_CHAT\": {\r\n \"DASHBOARD\": 65,\r\n \"CHAT\": 35\r\n },\r\n \"CHAT_CHATHISTORY\": {\r\n \"CHAT\": 80,\r\n \"CHATHISTORY\": 20\r\n }\r\n }\r\n },\r\n \"charts\": [\r\n {\r\n \"id\": \"SATISFIED\",\r\n \"name\": \"Satisfied\",\r\n \"type\": \"card\",\r\n \"layout\": { \"row\": 1, \"column\": 1, \"height\": 11 }\r\n },\r\n {\r\n \"id\": \"TOTAL_CALLS\",\r\n \"name\": \"Total Calls\",\r\n \"type\": \"card\",\r\n \"layout\": { \"row\": 1, \"column\": 2, \"span\": 1 }\r\n },\r\n {\r\n \"id\": \"AVG_HANDLING_TIME\",\r\n \"name\": \"Average Handling Time\",\r\n \"type\": \"card\",\r\n \"layout\": { \"row\": 1, \"column\": 3, \"span\": 1 }\r\n },\r\n {\r\n \"id\": \"SENTIMENT\",\r\n \"name\": \"Topics Overview\",\r\n \"type\": \"donutchart\",\r\n \"layout\": { \"row\": 2, \"column\": 1, \"width\": 40, \"height\": 44.5 }\r\n },\r\n {\r\n \"id\": \"AVG_HANDLING_TIME_BY_TOPIC\",\r\n \"name\": \"Average Handling Time By Topic\",\r\n \"type\": \"bar\",\r\n \"layout\": { \"row\": 2, \"column\": 2, \"row-span\": 2, \"width\": 60 }\r\n },\r\n {\r\n \"id\": \"TOPICS\",\r\n \"name\": \"Trending Topics\",\r\n \"type\": \"table\",\r\n \"layout\": { \"row\": 3, \"column\": 1, \"span\": 2 }\r\n },\r\n {\r\n \"id\": \"KEY_PHRASES\",\r\n \"name\": \"Key Phrases\",\r\n \"type\": \"wordcloud\",\r\n \"layout\": { \"row\": 3, \"column\": 2, \"height\": 44.5 }\r\n }\r\n ]\r\n}", |
2038 |
| - "keyVaultSecretsOfficerId": "b86a8fe4-44ce-4948-aee5-eccb2c155cd7" |
| 2060 | + "reactAppLayoutConfig": "{\r\n \"appConfig\": {\r\n \"THREE_COLUMN\": {\r\n \"DASHBOARD\": 50,\r\n \"CHAT\": 33,\r\n \"CHATHISTORY\": 17\r\n },\r\n \"TWO_COLUMN\": {\r\n \"DASHBOARD_CHAT\": {\r\n \"DASHBOARD\": 65,\r\n \"CHAT\": 35\r\n },\r\n \"CHAT_CHATHISTORY\": {\r\n \"CHAT\": 80,\r\n \"CHATHISTORY\": 20\r\n }\r\n }\r\n },\r\n \"charts\": [\r\n {\r\n \"id\": \"SATISFIED\",\r\n \"name\": \"Satisfied\",\r\n \"type\": \"card\",\r\n \"layout\": { \"row\": 1, \"column\": 1, \"height\": 11 }\r\n },\r\n {\r\n \"id\": \"TOTAL_CALLS\",\r\n \"name\": \"Total Calls\",\r\n \"type\": \"card\",\r\n \"layout\": { \"row\": 1, \"column\": 2, \"span\": 1 }\r\n },\r\n {\r\n \"id\": \"AVG_HANDLING_TIME\",\r\n \"name\": \"Average Handling Time\",\r\n \"type\": \"card\",\r\n \"layout\": { \"row\": 1, \"column\": 3, \"span\": 1 }\r\n },\r\n {\r\n \"id\": \"SENTIMENT\",\r\n \"name\": \"Topics Overview\",\r\n \"type\": \"donutchart\",\r\n \"layout\": { \"row\": 2, \"column\": 1, \"width\": 40, \"height\": 44.5 }\r\n },\r\n {\r\n \"id\": \"AVG_HANDLING_TIME_BY_TOPIC\",\r\n \"name\": \"Average Handling Time By Topic\",\r\n \"type\": \"bar\",\r\n \"layout\": { \"row\": 2, \"column\": 2, \"row-span\": 2, \"width\": 60 }\r\n },\r\n {\r\n \"id\": \"TOPICS\",\r\n \"name\": \"Trending Topics\",\r\n \"type\": \"table\",\r\n \"layout\": { \"row\": 3, \"column\": 1, \"span\": 2 }\r\n },\r\n {\r\n \"id\": \"KEY_PHRASES\",\r\n \"name\": \"Key Phrases\",\r\n \"type\": \"wordcloud\",\r\n \"layout\": { \"row\": 3, \"column\": 2, \"height\": 44.5 }\r\n }\r\n ]\r\n}" |
2039 | 2061 | },
|
2040 | 2062 | "resources": [
|
2041 | 2063 | {
|
|
2051 | 2073 | "[resourceId('Microsoft.Resources/deployments', format('{0}-app-module', variables('name')))]"
|
2052 | 2074 | ]
|
2053 | 2075 | },
|
2054 |
| - { |
2055 |
| - "type": "Microsoft.Authorization/roleAssignments", |
2056 |
| - "apiVersion": "2022-04-01", |
2057 |
| - "scope": "[format('Microsoft.KeyVault/vaults/{0}', parameters('keyVaultName'))]", |
2058 |
| - "name": "[guid(resourceId('Microsoft.KeyVault/vaults', parameters('keyVaultName')), subscriptionResourceId('Microsoft.Authorization/roleDefinitions', variables('keyVaultSecretsOfficerId')))]", |
2059 |
| - "properties": { |
2060 |
| - "roleDefinitionId": "[subscriptionResourceId('Microsoft.Authorization/roleDefinitions', variables('keyVaultSecretsOfficerId'))]", |
2061 |
| - "principalId": "[reference(resourceId('Microsoft.Resources/deployments', format('{0}-app-module', variables('name'))), '2022-09-01').outputs.identityPrincipalId.value]", |
2062 |
| - "principalType": "ServicePrincipal" |
2063 |
| - }, |
2064 |
| - "dependsOn": [ |
2065 |
| - "[resourceId('Microsoft.Resources/deployments', format('{0}-app-module', variables('name')))]" |
2066 |
| - ] |
2067 |
| - }, |
2068 | 2076 | {
|
2069 | 2077 | "type": "Microsoft.Resources/deployments",
|
2070 | 2078 | "apiVersion": "2022-09-01",
|
|
2088 | 2096 | "value": "[parameters('userassignedIdentityId')]"
|
2089 | 2097 | },
|
2090 | 2098 | "appSettings": {
|
2091 |
| - "value": "[union(parameters('appSettings'), createObject('APPINSIGHTS_INSTRUMENTATIONKEY', reference(parameters('applicationInsightsId'), '2015-05-01').InstrumentationKey, 'REACT_APP_LAYOUT_CONFIG', variables('reactAppLayoutConfig')))]" |
| 2099 | + "value": "[union(parameters('appSettings'), createObject('AZURE_OPENAI_API_KEY', parameters('azureOpenAIKey'), 'AZURE_AI_SEARCH_API_KEY', parameters('azureSearchAdminKey'), 'AZURE_AI_PROJECT_CONN_STRING', parameters('azureAiProjectConnString'), 'APPINSIGHTS_INSTRUMENTATIONKEY', reference(parameters('applicationInsightsId'), '2015-05-01').InstrumentationKey, 'REACT_APP_LAYOUT_CONFIG', variables('reactAppLayoutConfig')))]" |
2092 | 2100 | }
|
2093 | 2101 | },
|
2094 | 2102 | "template": {
|
|
2273 | 2281 | "[extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.Resources/deployments', 'deploy_ai_foundry')]",
|
2274 | 2282 | "[extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.Resources/deployments', 'deploy_cosmos_db')]",
|
2275 | 2283 | "[resourceId('Microsoft.Resources/deployments', 'deploy_app_service_plan')]",
|
2276 |
| - "[extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.Resources/deployments', 'deploy_keyvault')]", |
2277 | 2284 | "[extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.Resources/deployments', 'deploy_managed_identity')]",
|
2278 | 2285 | "[extensionResourceId(format('/subscriptions/{0}/resourceGroups/{1}', subscription().subscriptionId, resourceGroup().name), 'Microsoft.Resources/deployments', 'deploy_sql_db')]"
|
2279 | 2286 | ]
|
|
0 commit comments