0

I want to setup proxy in nginx:

location ~ ^/m/([^/]*)/([^/]*)/([^/]*)$ { proxy_pass http://127.0.0.1:8080/redir/m/$1/$2/$3; proxy_redirect off; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; } 

It works but this address

http:// myhost/m/test//ss 

gets translated to

http:// 127.0.0.1:8080/redir/m/test/ss; 

How can I get my second slash?? Thanx.

1 Answer 1

1
syntax: merge_slashes on | off; default: merge_slashes on; context: http, server

Enables or disables compression of two or more adjacent slashes in a URI into a single slash.

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.