envoyproxy / gateway

Manages Envoy Proxy as a Standalone or Kubernetes-based Application Gateway
https://gateway.envoyproxy.io
Apache License 2.0
1.63k stars 352 forks source link

How to add server_header_transformation in kind: EnvoyProxy #4324

Open meektechie opened 1 month ago

meektechie commented 1 month ago

Description:

Describe the desired behavior, what scenario it enables and how it would be used. I want to remove server: nginx/1.27.1 header on on my response header. I am using envoy-gateway. I want server_header_transformation this to be applied globally.
[optional Relevant Links:] Any extra documentation required to understand the issue.

Below i have attached my configuration. It did't works but need some experts guidelines.

`apiVersion: gateway.envoyproxy.io/v1alpha1 kind: EnvoyProxy metadata: name: external-proxy-config namespace: gateway spec: bootstrap: type: Merge value: | static_resources: listeners:

meektechie commented 1 month ago

apiVersion: gateway.envoyproxy.io/v1alpha1 kind: EnvoyProxy metadata: name: external-proxy-config namespace: gateway spec: bootstrap: type: Merge value: | static_resources: listeners:

arkodg commented 1 month ago

@meektechie its PASS_THROUGH by default https://github.com/envoyproxy/gateway/pull/2585/files are you on v1.1 ?

meektechie commented 1 month ago

@arkodg Yes it is v1.1.1. I followed the doc https://www.envoyproxy.io/docs/envoy/latest/api-v3/extensions/filters/network/http_connection_manager/v3/http_connection_manager.proto.html#envoy-v3-api-enum-extensions-filters-network-http-connection-manager-v3-httpconnectionmanager-serverheadertransformation. there it is mentioned default is OVERWRITE. I am new to it. I want to remove the "Server" header globally for all the HTTPRoutes. Pls suggest how can i proceed.

arkodg commented 1 month ago

@meektechie Envoy Proxy sets the default to OvERWRITE but Envoy Gateway sets the default to PASSTHROUGH

meektechie commented 1 month ago

Great, but still i could see the server header. Am i missing something?

github-actions[bot] commented 3 weeks ago

This issue has been automatically marked as stale because it has not had activity in the last 30 days.