-
Notifications
You must be signed in to change notification settings - Fork 183
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Accept Multi Values in One Header When Using byHttpHeader #219
base: master
Are you sure you want to change the base?
Conversation
Signed-off-by: Kirchen99 <latias_latios@126.com>
Signed-off-by: Kirchen99 <latias_latios@126.com>
Hi, this commit that is merged into kube-rbac-proxy enables to specify the same header several times and all of them should be taken into consideration: Is this enough to satisfy your needs? |
Not really. We use kube-rbac-proxy for Grafana Loki. Grafana Loki accepts only one header value and separating their names by the Maybe I should have a look at Grafana Loki, if it is possible to make a PR to let it accept same header several times. Here is the document from Grafana Loki:
|
Hi @ibihim, we would also find this feature super helpful, could you maybe look at this PR again? |
@@ -53,6 +53,7 @@ type QueryParameterRewriteConfig struct { | |||
// be used to rewrite a SubjectAccessReview on a given request. | |||
type HTTPHeaderRewriteConfig struct { | |||
Name string `json:"name,omitempty"` | |||
Sep string `json:"separator,omitempty"` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sep string `json:"separator,omitempty"` | |
Separator string `json:"separator,omitempty"` |
NB: I'm not a reviewer here, just adding a suggestion.
Description
This PR extends the feature in #104. With a "separator" in the config the header value can be split.
e.g.
Motivation
We also put kube-rbac-proxy in front of Loki (https://grafana.com/docs/loki/latest/). And Loki 2.6 enabled multi-tenant queries: https://grafana.com/blog/2022/07/27/grafana-loki-2.6-release/
The required format from loki is like this: