5

I want to accomplish something like

https://companyname.net/admin/identity routed to https://localhost:9443 https://companyname.net/admin/identity/a/b/c routed to https://localhost:9443/a/b/c

How to do those the neatest possible way?

Current Config:

location /admin/identity$path {
  proxy_pass https://localhost:9443$path;
}
1

2 Answers 2

11

try location config like this:

location ~ /admin/identity/(.*) {
    proxy_pass https://localhost:9443/$1;
}
Sign up to request clarification or add additional context in comments.

1 Comment

That does not match /admin/identity, only /admin/identity/
7

That's copy of an answer from https://serverfault.com/a/586614/211028

location /admin/identity/ {
    proxy_pass https://localhost:9443/;
}

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.