Skip to content

allow using regex in the redirect plugin #3722

Description

@byte-kevin

Issue description

I can't find how to config apisix to support regular matching in uri. The nginx configuration is as follows:

location ~* /lib/([a-fA-F0-9]+)$ {
    return 301 https://example.com/lib/all/$1;
}

Environment

  • apisix version (cmd: apisix version):2.2
  • OS (cmd: uname -a):ubantu
  • OpenResty / Nginx version (cmd: nginx -V or openresty -V):
  • etcd version, if have (cmd: run curl http://127.0.0.1:9090/v1/server_info to get the info from server-info API):
  • apisix-dashboard version, if have:2.3

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions