Skip to content

Commit 72c4ccc

Browse files
committed
chore: expose additional port when using qdrant grpc
1 parent 3bcfbca commit 72c4ccc

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

infra/core/host/container-app.bicep

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,15 @@ param targetPort int = 80
1515
param allowedOrigins array = []
1616
param transport string = 'auto'
1717
param allowInsecure bool = false
18+
param additionalPortMappings array = []
1819

1920
@description('CPU cores allocated to a single container instance, e.g. 0.5')
2021
param containerCpuCoreCount string = '0.5'
2122

2223
@description('Memory allocated to a single container instance, e.g. 1Gi')
2324
param containerMemory string = '1.0Gi'
2425

25-
resource app 'Microsoft.App/containerApps@2023-05-01' = {
26+
resource app 'Microsoft.App/containerApps@2023-11-02-preview' = {
2627
name: name
2728
location: location
2829
tags: tags
@@ -39,6 +40,7 @@ resource app 'Microsoft.App/containerApps@2023-05-01' = {
3940
corsPolicy: {
4041
allowedOrigins: empty(allowedOrigins) ? ['*'] : allowedOrigins
4142
}
43+
additionalPortMappings: additionalPortMappings
4244
}
4345
secrets: concat(secrets, [
4446
{

infra/main.bicep

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -325,6 +325,11 @@ module qdrant './core/host/container-app.bicep' = if (useQdrant) {
325325
allowInsecure: (qdrantPort == 6334 ? true : false)
326326
// gRPC needs to be explicitly set for HTTP2
327327
transport: (qdrantPort == 6334 ? 'HTTP2' : 'auto')
328+
additionalPortMappings: (qdrantPort == 6334 ? [{
329+
// external: false
330+
targetPort: 6333
331+
exposedPort: 6333
332+
}] : [])
328333
}
329334
}
330335

0 commit comments

Comments
 (0)