Nginx proxy pass: различия между версиями
Материал из noname.com.ua
Перейти к навигацииПерейти к поискуSirmax (обсуждение | вклад) |
Sirmax (обсуждение | вклад) |
||
Строка 7: | Строка 7: | ||
|+ Файлы |
|+ Файлы |
||
|- |
|- |
||
− | + | ! location !! proxy_pass !! Пример конфигурации !! Request !! Received by upstream |
|
|- |
|- |
||
| |
| |
||
− | <code>/test_links |
+ | <code>/test_links</code> |
|| |
|| |
||
+ | <code>/new_location</code> |
||
+ | || |
||
+ | <PRE> |
||
+ | location /test_links { |
||
+ | proxy_pass https://noname.com.ua/new_location; |
||
+ | } |
||
+ | </PRE> |
||
+ | || |
||
+ | * <code>/test_links?foo=bar</code> |
||
+ | * <code>/test_links/baz?foo=bar</code> |
||
+ | || |
||
+ | * <code>"POST /new_location?foo=bar</code> |
||
+ | * <code>POST /new_location/baz?foo=bar</code> |
||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |- |
||
+ | | |
||
<code>/test_links</code> |
<code>/test_links</code> |
||
|| |
|| |
||
Строка 27: | Строка 46: | ||
* <code>"POST /new_location?foo=bar</code> |
* <code>"POST /new_location?foo=bar</code> |
||
* <code>POST /new_location/baz?foo=bar</code> |
* <code>POST /new_location/baz?foo=bar</code> |
||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
|- |
|- |
||
− | | |
+ | | |
+ | <code>/test_links</code> |
||
− | Текст ячейки |
||
+ | || |
||
+ | <code>/new_location</code> |
||
+ | || |
||
+ | <PRE> |
||
+ | location /test_links { |
||
+ | proxy_pass https://noname.com.ua/new_location; |
||
+ | } |
||
+ | </PRE> |
||
+ | || |
||
+ | * <code>/test_links?foo=bar</code> |
||
+ | * <code>/test_links/baz?foo=bar</code> |
||
+ | || |
||
+ | * <code>"POST /new_location?foo=bar</code> |
||
+ | * <code>POST /new_location/baz?foo=bar</code> |
||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |- |
||
+ | | |
||
+ | <code>/test_links</code> |
||
+ | || |
||
+ | <code>/new_location</code> |
||
+ | || |
||
+ | <PRE> |
||
+ | location /test_links { |
||
+ | proxy_pass https://noname.com.ua/new_location; |
||
+ | } |
||
+ | </PRE> |
||
|| |
|| |
||
− | <code> |
+ | * <code>/test_links?foo=bar</code> |
+ | * <code>/test_links/baz?foo=bar</code> |
||
+ | || |
||
+ | * <code>"POST /new_location?foo=bar</code> |
||
+ | * <code>POST /new_location/baz?foo=bar</code> |
||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
|- |
|- |
||
+ | | |
||
− | | Текст ячейки || Текст ячейки |
||
+ | <code>/test_links</code> |
||
+ | || |
||
+ | <code>/new_location</code> |
||
+ | || |
||
+ | <PRE> |
||
+ | location /test_links { |
||
+ | proxy_pass https://noname.com.ua/new_location; |
||
+ | } |
||
+ | </PRE> |
||
+ | || |
||
+ | * <code>/test_links?foo=bar</code> |
||
+ | * <code>/test_links/baz?foo=bar</code> |
||
+ | || |
||
+ | * <code>"POST /new_location?foo=bar</code> |
||
+ | * <code>POST /new_location/baz?foo=bar</code> |
||
+ | |||
|} |
|} |
Версия 08:59, 9 июля 2024
Nginx proxy_pass
location | proxy_pass | Пример конфигурации | Request | Received by upstream |
---|---|---|---|---|
|
|
location /test_links { proxy_pass https://noname.com.ua/new_location; } |
|
|
|
|
location /test_links { proxy_pass https://noname.com.ua/new_location; } |
|
|
|
|
location /test_links { proxy_pass https://noname.com.ua/new_location; } |
|
|
|
|
location /test_links { proxy_pass https://noname.com.ua/new_location; } |
|
|
|
|
location /test_links { proxy_pass https://noname.com.ua/new_location; } |
|
|