【发布时间】:2021-01-18 16:07:25
【问题描述】:
我正在摆弄 dataplaneapi,这是一个很好的补充。 但是,我无法在我的前端找到适当的参数来操作 http 请求。规则需要如下所示:
http-request replace-header Host .* 1595708099.pages.domain.de if ACL_somename_de
我当前的请求转到 http_request_rules 端点:/services/haproxy/configuration/http_request_rules 请求正文如下所示:
{ "cond": "if", "cond_test": "ACL_somename_de", "hdr_name": "Host", "index": 0, "type": "replace-header" }
输出是:
http-request replace-header Host if ACL_somename_de
但是我仍然缺少正则表达式条件部分。在常规的 HAproxy 文档上,它被称为和 看: https://www.haproxy.com/documentation/aloha/12-5/traffic-management/lb-layer7/http-rewrite/
我在 dataplane 文档中找不到这些值。 https://www.haproxy.com/documentation/dataplaneapi/latest/#operation/createHTTPRequestRule
这甚至可能吗?如果可以,如何?
【问题讨论】:
标签: httprequest haproxy api-gateway