Last active
January 12, 2018 10:09
-
-
Save e7/e808e34afcfdebbb2e4813c3c560d1cc to your computer and use it in GitHub Desktop.
capture location for nginx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
location /capture/ { | |
internal; | |
rewrite ^/capture/(https?)/([^/]+)/(\d+)/(.*) /$4 break; | |
proxy_pass $1://$2:$3; | |
} | |
usage like this: | |
-- url: http://www.hejizhan.com/s/forum.php | |
ngx.location.capture("/capture/http/www.hejizhan.com/80/s/forum.php" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment