Nginx服务器无法找到符合请求的匹配位置

我正在努力找出正确的正则表达式来匹配任何遵循以下模式的请求。

/outputresources/blahbalh/blahblahhhhh/file.gkg
/outputresources/blah8888/file
/outputresources/b;aaaaahhh/blah/blaaaahhhhh/file

我还想捕获/outputresource/后跟的任何值,以便在我的lua脚本中获取它。

尝试过的正则表达式

~ /outputResources/(?P<file>(.*)*)
~ /outputResources/(?P<file>(.*/*)*)

我正在使用openresty nginx

点赞