Currently, we run our kubernetes application in a cluster with the EFK (Elastic Search, Fluent-bit, and Kibana) stack. Our application is comprised of multiple pods/services but there are no other applications running in the cluster (except for native Kubernetes and the EFK stack).
When we deliver to our customer, we will be deploying to a multi-tenant cluster where our application will be running in the same cluster as other applications. Our application needs to provide it’s own logging solution (we only care about logs associated with our application) but fluent-bit currently scrapes any pods running in the cluster.
I am looking into Loki for log collection and visualization. Is there a way that I can deploy loki and configure it to only scrape logs associated with our application (via an annotation, label, etc.)?
In preparation for helping our customer, I would like to understand how to deploy Loki in a multi-tenant way and then configure it to only scrape our application. Then as we understand and learn how it works, we can educate our customer how they can configure logging for other applciations running in their cluster. Is there a way to configure promtail to only scrape logs from certain namespaces, with specific labels/annotations, etc.