Open etiennep opened 3 months ago
This issue has not had any activity in the past 30 days, so the needs-attention
label has been added to it.
If the opened issue is a bug, check to see if a newer release fixed your issue. If it is no longer relevant, please feel free to close this issue.
The needs-attention
label signals to maintainers that something has fallen through the cracks. No action is needed by you; your issue will be kept open and you do not have to respond to this comment. The label will be removed the next time this job runs if there is new activity.
Thank you for your contributions!
I can take this issue if someone can assign it to me.
Request
Container lifecycle hook support is needed as an option in the helm chart to handle graceful pod termination when deployed behind an AWS Application Loadbalancer.
Use case
When using Grafana Alloy in a Kubernetes deployment and with an Ingress provisioned by the AWS ALB Ingress controller, it is required that you use a PreStop lifecycle hook. This is needed to pause the termination of the pod/container to allow the ALB to drain its connection before terminating the pod. Otherwise, an early pod termination may lead to 5xx errors being sent to the client.
This can be mitigated by configuring the deregistration delay on the target group (using ingress annotations) and adding a PreStop hook to pause the termination of the pod and allow it to be deregistered from the target group before it gets terminated.
See AWS ALB Controller issue: https://github.com/kubernetes-sigs/aws-load-balancer-controller/issues/1064