From be2cb91221c6a79ee9a23d34d748b2e3c0003a65 Mon Sep 17 00:00:00 2001 From: Dayenne Souza Date: Tue, 17 Dec 2024 10:58:07 -0300 Subject: [PATCH] fix template azure marketplace --- deploy/azure/createUiDefinition.json | 12 ++++++------ deploy/azure/mainTemplate.json | 3 ++- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/deploy/azure/createUiDefinition.json b/deploy/azure/createUiDefinition.json index 64a8a25..f13abd0 100644 --- a/deploy/azure/createUiDefinition.json +++ b/deploy/azure/createUiDefinition.json @@ -70,11 +70,11 @@ "allowedValues": [ { "label": "OpenAI", - "value": "openai" + "value": "OpenAI" }, { "label": "Azure OpenAI", - "value": "azure" + "value": "Azure OpenAI" } ], "required": true @@ -86,7 +86,7 @@ "type": "Microsoft.Common.CheckBox", "label": "Use Managed Identity", "toolTip": "Use Managed Identity to authenticate to Azure AI", - "visible": "[equals(steps('AISettings').aiType, 'azure')]" + "visible": "[equals(steps('AISettings').aiType, 'Azure OpenAI')]" }, { "name": "aiEndpoint", @@ -95,11 +95,11 @@ "toolTip": "The endpoint of the Azure AI service", "defaultValue": "", "constraints": { - "required": "[equals(steps('AISettings').aiType, 'azure')]", + "required": "[equals(steps('AISettings').aiType, 'Azure OpenAI')]", "regex": "^(https://)([a-zA-Z0-9-]+)(.openai.azure.com)$", "validationMessage": "Must be a valid Azure AI endpoint" }, - "visible": "[equals(steps('AISettings').aiType, 'azure')]" + "visible": "[equals(steps('AISettings').aiType, 'Azure OpenAI')]" }, { "name": "openaiApiKey", @@ -112,7 +112,7 @@ "validationMessage": "Must be a valid OpenAI key" }, "defaultValue": "", - "visible": "[or(equals(steps('AISettings').aiManagedIdentity, false), equals(steps('AISettings').aiType, 'openai'))]" + "visible": "[or(equals(steps('AISettings').aiManagedIdentity, false), equals(steps('AISettings').aiType, 'OpenAI'))]" } ] }, diff --git a/deploy/azure/mainTemplate.json b/deploy/azure/mainTemplate.json index 089f62b..40bf755 100644 --- a/deploy/azure/mainTemplate.json +++ b/deploy/azure/mainTemplate.json @@ -118,7 +118,7 @@ }, { "name": "AZURE_AUTH_TYPE", - "value": "[if(equals(parameters('aiManagedIdentity'), 'true'), 'Managed Identity', 'Azure Key')]" + "value": "[if(parameters('aiManagedIdentity'), 'Managed Identity', 'Azure Key')]" }, { "name": "AZURE_OPENAI_ENDPOINT", @@ -162,6 +162,7 @@ { "type": "Microsoft.Web/sites/config", "apiVersion": "2022-09-01", + "condition": "[equals(parameters('disableAuth'), 'false')]", "name": "[concat(parameters('webAppName'), '/authsettingsV2')]", "dependsOn": [ "[resourceId('Microsoft.Web/Sites', parameters('webAppName'))]"