Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
…into skm-19155-2
  • Loading branch information
saimachi committed Oct 18, 2024
2 parents 5e03f78 + 970c60a commit 013b364
Show file tree
Hide file tree
Showing 46 changed files with 1,296 additions and 1,788 deletions.
20 changes: 19 additions & 1 deletion deploy/common/config/openAiDeploymentConfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,25 @@
"version": "2024-05-13"
},
"sku": {
"capacity": 8,
"capacity": 100,
"name": "Standard"
}
},
{
"name": "dall-e-3",
"locations": [
"austrailiaeast",
"eastus",
"swedencentral"
],
"raiPolicyName": "",
"model": {
"format": "OpenAI",
"name": "dall-e-3",
"version": "3.0"
},
"sku": {
"capacity": 1,
"name": "Standard"
}
},
Expand Down
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
completion-*model.json
embedding-model.json
embedding-model.json
dall-e-3-model.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,13 @@
"ResourceReferences": [
{
"Name": "DefaultCompletionAIModel",
"Filename": "/FoundationaLLM.AIModel/completion-model.json",
"Filename": "/FoundationaLLM.AIModel/completion-4o-model.json",
"Type": "completion",
"Deleted": false
},
{
"Name": "DALLE3Model",
"Filename": "/FoundationaLLM.AIModel/dall-e-3-model.json",
"Type": "completion",
"Deleted": false
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,4 @@ GatewayAdapterAPI.json
AzureOpenAI.json
AzureAISearch.json
AzureEventGrid.json
OneDriveFileStoreConnector.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,12 @@
"Type": "api-endpoint",
"Deleted": false
},
{
"Name": "AzureOpenAIDALLE",
"Filename": "/FoundationaLLM.Configuration/AzureOpenAIDALLE.json",
"Type": "api-endpoint",
"Deleted": false
},
{
"Name": "GatekeeperAPI",
"Filename": "/FoundationaLLM.Configuration/GatekeeperAPI.json",
Expand Down Expand Up @@ -42,6 +48,12 @@
"Type": "api-endpoint",
"Deleted": false
},
{
"Name": "OneDriveFileStoreConnector",
"Filename": "/FoundationaLLM.Configuration/OneDriveFileStoreConnector.json",
"Type": "api-endpoint",
"Deleted": false
},
{
"Name": "SemanticKernelAPI",
"Filename": "/FoundationaLLM.Configuration/SemanticKernelAPI.json",
Expand Down
18 changes: 16 additions & 2 deletions deploy/common/scripts/Create-FllmEntraIdApps.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,21 @@
- FoundationaLLM-Core-Portal
- FoundationaLLM-Management-API
- FoundationaLLM-Management-Portal
- FoundationaLLM-Reader
The script will also assign the required permissions to the client apps and the required API permissions to the API apps.
The script will also assign the required permissions to the client apps and the required API permissions to the API apps.
Users can be added as Owners of the app registrations by creating an `admins.json` file in the `deploy/common/config` folder
with the following JSON array content
```json
[
"[email protected]",
"[email protected]"
]
```
> Note: Only members of the resident tenant will be able to be imported in this manner. Accounts outside of the tenant will
be ignored.
.REQUIREMENTS
- The user must be a Global Administrator in the Entra ID tenant or have RBAC rights to create App Registrations and Service Principals.
Expand All @@ -24,6 +37,7 @@
- foundationallm-core-portal.template.json
- foundationallm-management-api.template.json
- foundationallm-management-portal.template.json
- foundationallm-reader.template.json
.PARAMETER appPermissionsId
The GUID of the permission to assign to the client app.
Expand Down Expand Up @@ -169,7 +183,7 @@ function New-FllmEntraIdApps {
## Updates the Client App Registration
Write-Host -ForegroundColor Yellow "Preparing updates for the Client App Registration $($fllmAppRegMetaData.Client.Name)"
$($fllmAppRegMetaData.Client).Uri = @("api://$($fllmAppRegMetaData.Client.Name)")
$apiPermissions = @(@{"resourceAppId" = $($fllmAppRegMetaData.Client.AppId); "resourceAccess" = @(@{"id" = "$($appPermissionsId)"; "type" = "Scope" }) }, @{"resourceAppId" = "00000003-0000-0000-c000-000000000000"; "resourceAccess" = @(@{"id" = "e1fe6dd8-ba31-4d61-89e7-88639da4683d"; "type" = "Scope" }) })
$apiPermissions = @(@{"resourceAppId" = $($fllmAppRegMetaData.Api.AppId); "resourceAccess" = @(@{"id" = "$($appPermissionsId)"; "type" = "Scope" }) }, @{"resourceAppId" = "00000003-0000-0000-c000-000000000000"; "resourceAccess" = @(@{"id" = "e1fe6dd8-ba31-4d61-89e7-88639da4683d"; "type" = "Scope" }) })
$appConfig = Get-content $fllmClientConfigPath | ConvertFrom-Json -Depth 20
$appConfig.identifierUris = @($($fllmAppRegMetaData.Client.Uri))
$appConfig.requiredResourceAccess = $apiPermissions
Expand Down
9 changes: 7 additions & 2 deletions deploy/common/scripts/Remove-FllmEntraIdApps.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,15 @@
.PARAMETER mgmtClientAppName
The display name of the Management Portal application to be deleted. Default is "FoundationaLLM-Management-Portal".
.PARAMETER mgmtClientAppName
The display name of the Reader application to be deleted. Default is "FoundationaLLM-Reader".
.PARAMETER interactiveMode
Boolean flag to determine if the script should run in interactive mode, prompting for user confirmation before deletion.
Default is $true.
.EXAMPLE
./Remove-EntraIdMApps.ps1
./Remove-FllmEntraIdApps.ps1
This example runs the script to delete the default Entra applications prompting for confirmation.
.NOTES
Expand All @@ -44,6 +47,7 @@ Param(
[parameter(Mandatory = $false)][string]$coreClientAppName="FoundationaLLM-Core-Portal",
[parameter(Mandatory = $false)][string]$mgmtAppName="FoundationaLLM-Management-API",
[parameter(Mandatory = $false)][string]$mgmtClientAppName="FoundationaLLM-Management-Portal",
[parameter(Mandatory = $false)][string]$mgmtReaderAppName = "FoundationaLLM-Reader",
[parameter(Mandatory=$false)][bool]$interactiveMode = $true
)

Expand All @@ -58,7 +62,8 @@ $AppNames = @(
$coreAppName,
$coreClientAppName,
$mgmtAppName,
$mgmtClientAppName
$mgmtClientAppName,
$mgmtReaderAppName
)

# Function to filter and delete Azure AD applications based on display name
Expand Down
2 changes: 1 addition & 1 deletion deploy/common/scripts/Restart-FllmAks.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
param (
[Parameter(Mandatory = $true)][string[]]$aksClusterNames,
[Parameter(Mandatory = $true)][string]$resourceGroupName,
[Parameter(Mandatory = $true)][string[]]$namespaces = @("gateway-system", "fllm")
[Parameter(Mandatory = $false)][string[]]$namespaces = @("gateway-system", "fllm")
)

# Set Debugging and Error Handling
Expand Down
Loading

0 comments on commit 013b364

Please sign in to comment.