The format is simple: proxy_pass URL; The URL includes: transmission protocol (http://, https://, etc.), host name (domain name or IP:PORT), and uri. Here is an example: proxy_pass http://www.xxx.com/; proxy_pass http://192.168.200.101:8080/uri; proxy_pass unix:/tmp/www.sock; There are several things to note about proxy_pass configuration: Assume server_name is www.xxx.com When requesting http://www.xxx.com/aming/a.html, the results of the above examples are Example 1: location /aming/ { proxy_pass http://192.168.1.10; ... } Result 1: http://192.168.1.10/aming/a.html Example 2: location /aming/ { proxy_pass http://192.168.1.10/; ... } Result 2: http://192.168.1.10/a.html Example 3: location /aming/ { proxy_pass http://192.168.1.10/linux/; ... } Result 3: http://192.168.1.10/linux/a.html Example 4: location /aming/ { proxy_pass http://192.168.1.10/linux; ... } Result 4: http://192.168.1.10/linuxa.html Summarize: For ease of memory and standardized configuration, it is recommended that all URLs after proxy_pass end with "/". proxy_pass http://192.168.1.10/linux/; This is the end of this article about the implementation of proxy_pass in nginx reverse proxy. For more relevant nginx reverse proxy proxy_pass content, please search for previous articles on 123WORDPRESS.COM or continue to browse the following related articles. I hope you will support 123WORDPRESS.COM in the future! You may also be interested in:
|
<<: Vue implements a simple shopping cart example
>>: Summary of HTML formatting standards for web-based email content
Table of contents 1. Introduction to SELinux 2. B...
In Ubuntu, you often encounter the situation wher...
Summary: Problem solving records of MYSQL: No mat...
This article guide: There are two ways to delete ...
This article shares the specific code of javascri...
Preface If CSS is the basic skill of front-end de...
A few days ago, the library said that the server ...
HTML <div class="spinner"></di...
MySQL filtering timing of where conditions and ha...
A large part of data management is searching, and...
Beginners can learn HTML by understanding some HT...
Problem Description Install nginx on Tencent Clou...
login.html part: <!DOCTYPE html> <html l...
Table of contents Hbase installation and configur...
The essence of a flat website structure is simpli...