I tried setting up with envoy filter using the below code:
apiVersion: networking.istio.io/v1alpha3
kind: EnvoyFilter
metadata:
name: proxy-headers-lua
namespace: default
spec:
workloadSelector:
labels:
app: web
configPatches:
# The first patch adds the lua filter to the listener/http connection manager
- applyTo: HTTP_FILTER
match:
context: SIDECAR_INBOUND
patch:
operation: INSERT_BEFORE
value: # lua filter specification
name: envoy.lua
config:
inlineCode: |
function envoy_on_request(request_handle)
body_size = request_handle:body():length()
request_handle:headers():add("request-body-size", tostring(body_size))
request_handle:httpCall(300000)
end
but it doesn't seem to be taking affect. when i curl post request to web app with data > 2mb it throws http error 413