-
Notifications
You must be signed in to change notification settings - Fork 543
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support of try_files
usage
#840
Comments
We will implement this functionality through plugins instead of annotations This feature can be implemented by using routeCluster in the plugin and using it with httpcall. reference:
httpCall:
|
may I have a try for this,write a go wasm plugin |
@OnlyPiglet Are you finished the feature, i also have the need for it。 |
@haifzhu |
|
主逻辑是不是这样的? |
@haifzhu 有点问题,应该在回调里迭代处理下一个trypath |
可以添加一个nginx的proxy_cache 缓存功能做请求容灾 |
@haifzhu 这个PR是不是忘记重新提交了 |
Why do you need it?
When serving some static files with app, users want to access files with or without suffix.
How could it be?
Implement one annotation witch support
try_files
actions, like below:higress.io/try_files: '$1 $1.html $1/index.html $1/'
.When user access one path, try response content of some more paths, eg, when user access
example.com/a
, response content using/a
,/a.html
,/a/index.html
,/a/
inorder, and only return non 200 status code when all these paths returns null.Other related information
nginx/try_files
The text was updated successfully, but these errors were encountered: