Skip to content

Commit 5916f46

Browse files
committed
[PFMENG-3093] add k8 api endpoint
1 parent 220f65a commit 5916f46

File tree

3 files changed

+8
-1
lines changed

3 files changed

+8
-1
lines changed

modules/essentials/fluent_bit.tf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ locals {
4141
excluded_namespaces = var.fluent_bit_excluded_namespaces,
4242
s3_bucket_name = var.fluent_bit_enable_s3_output ? module.fluentbit_s3_bucket[0].s3_bucket_id : null,
4343
cw_enable = var.fluent_bit_enable_cw_output
44+
kube_api_endpoint = var.fluent_bit_kube_api_endpoint
4445
})
4546

4647
fluent_bit_helm_config = merge(

modules/essentials/templates/fluent_bit.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ config:
9292
[FILTER]
9393
Name kubernetes
9494
Match kube.*
95-
Kube_URL https://kubernetes.default.svc.cluster.local:443
95+
Kube_URL ${kube_api_endpoint}
9696
Merge_Log On
9797
Keep_Log Off
9898
K8S-Logging.Parser On

modules/essentials/variables.tf

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1571,6 +1571,12 @@ variable "fluent_bit_tolerations" {
15711571
]
15721572
}
15731573

1574+
variable "fluent_bit_kube_api_endpoint" {
1575+
description = "Kube API endpoint for fluent-bit"
1576+
type = string
1577+
default = "https://kubernetes.default.svc.cluster.local:443"
1578+
}
1579+
15741580
variable "ip_dual_stack_enabled" {
15751581
description = "Enable essentials to support EKS dual stack cluster"
15761582
type = bool

0 commit comments

Comments
 (0)