How do I get Kubernetes metadata about the Pods in Fargate Logs? #557
-
|
I deployed the eks-fargate-container-logs module module as a part of eks-core-services module. The log message is in a json object with a single key, {
"log": "2022-09-09T15:30:45.534811998Z stdout F "
}Is there anyway I can get more information, such as the pod labels? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
|
This is because by default the Fargate fargate_fluent_bit_extra_filters = <<-EOF
[FILTER]
Name kubernetes
Match kube.*
Merge_Log On
Buffer_Size 0
Kube_Meta_Cache_TTL 300s
EOF |
Beta Was this translation helpful? Give feedback.
This is because by default the Fargate
fluent-bitinstance does not extract the Kubernetes metadata from the pods when shipping the logs to the destination. You can configure thefluent-bitinstance to scrape the metadata by configuring thekubernetesfilter as an extra filter in the module. To do this, add the following to your module block orinputsmap interragrunt.hclwhen calling theeks-core-servicesmodule: