Skip to content

Commit

Permalink
Set X-Forwarded-Proto only if empty
Browse files Browse the repository at this point in the history
ocp routes add these header based on ssl config,
let's honor that and set this request header only in
httpd config only if it's empty.

Noticed this issue with pagination tests when deployed
control plane with tls.podlevel=false and tls.ingress=true.
  • Loading branch information
karelyatin authored and openshift-cherrypick-robot committed Dec 12, 2024
1 parent affa177 commit 8c6b7b8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions templates/neutronapi/httpd/10-neutron-httpd.conf
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@
## Request header rules
## as per http://httpd.apache.org/docs/2.2/mod/mod_headers.html#requestheader
{{- if $vhost.TLS }}
RequestHeader set X-Forwarded-Proto "https"
RequestHeader setIfEmpty X-Forwarded-Proto "https"
{{- else }}
RequestHeader set X-Forwarded-Proto "http"
RequestHeader setIfEmpty X-Forwarded-Proto "http"
{{- end }}

## Proxy rules
Expand Down

0 comments on commit 8c6b7b8

Please sign in to comment.