You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by GitBox <gi...@apache.org> on 2023/01/11 22:31:30 UTC
[GitHub] [apisix] niuguy commented on issue #4942: allow proxy-rewrite plugin to rewrite x-forwarded-port request header
niuguy commented on issue #4942:
URL: https://github.com/apache/apisix/issues/4942#issuecomment-1379569298
> For anyone needs workaround: Apply plugin serverless-pre-function to the route config Sample code:
>
> ```json
> "plugins": {
> "serverless-pre-function": {
> "phase": "rewrite",
> "functions": [
> "return function(conf, ctx) ngx.var.var_x_forwarded_port = 443 end"
> ]
> }
> },
> ```
Thank you so much bro.
btw for guys who use ingress controller
```
plugins:
- name: serverless-pre-function
enable: true
config:
phase: "rewrite"
functions: ["return function(conf, ctx) ngx.var.var_x_forwarded_port = 443 end"]
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org