Skip to content

Remove APIM from Bicep #17

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions infra/main.bicep
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,14 @@ param location string
param mcpTodoServerAppExists bool
param mcpTodoClientAppExists bool

@description('Id of the user or app to assign application roles')
param principalId string
//@description('Id of the user or app to assign application roles')
//param principalId string

@description('Whether to use the built-in login feature for the application or not')
param useLogin bool = true

@description('Whether to use API Management or not')
param useApiManagement bool = false
//@description('Whether to use API Management or not')
//param useApiManagement bool = false

@description('The connection string to OpenAI.')
@secure()
Expand Down Expand Up @@ -48,11 +48,11 @@ module resources 'resources.bicep' = {
environmentName: environmentName
location: location
tags: tags
principalId: principalId
//principalId: principalId
mcpTodoServerAppExists: mcpTodoServerAppExists
mcpTodoClientAppExists: mcpTodoClientAppExists
useLogin: useLogin
useApiManagement: useApiManagement
//useApiManagement: useApiManagement
openAIConnectionString: openAIConnectionString
}
}
Expand Down
13 changes: 8 additions & 5 deletions infra/resources.bicep
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,14 @@ param tags object = {}
param mcpTodoClientAppExists bool
param mcpTodoServerAppExists bool

@description('Id of the user or app to assign application roles')
param principalId string
//@description('Id of the user or app to assign application roles')
//param principalId string

@description('Whether to use the built-in login feature for the application or not')
param useLogin bool = true

@description('Whether to use API Management or not')
param useApiManagement bool = false
//@description('Whether to use API Management or not')
//param useApiManagement bool = false

@description('The connection string to OpenAI.')
@secure()
Expand Down Expand Up @@ -58,6 +58,7 @@ module storageAccount 'br/public:avm/res/storage/storage-account:0.15.0' = if (u
}
}

/*
// API Management
module apiManagement 'br/public:avm/res/api-management/service:0.9.1' = if (useApiManagement == true) {
name: 'apimanagement'
Expand Down Expand Up @@ -116,6 +117,7 @@ module apimApi './modules/apim-api.bicep' = if (useApiManagement == true) {
apimProduct
]
}
*/

// Container registry
module containerRegistry 'br/public:avm/res/container-registry/registry:0.6.0' = {
Expand Down Expand Up @@ -298,7 +300,8 @@ module mcpTodoClientApp 'br/public:avm/res/app/container-app:0.16.0' = {
}
{
name: 'McpServers__TodoList'
value: useApiManagement ? 'https://${apiManagement.outputs.name}.azure-api.net' : 'https://${mcpTodoServerApp.outputs.fqdn}'
value: 'https://${mcpTodoServerApp.outputs.fqdn}'
//value: useApiManagement ? 'https://${apiManagement.outputs.name}.azure-api.net' : 'https://${mcpTodoServerApp.outputs.fqdn}'
}
{
name: 'ConnectionStrings__OpenAI'
Expand Down