Home
Sign Up
Sign In
›
NGINX
›
NGINX Trac
›
3rd Party Modules
›
Security Advisories
›
CHANGES
›
OpenResty
›
ngx_lua
›
Tengine
在线学习资源
›
NGINX 开发从入门到精通
NGINX Modules
›
ngx_echo
V2EX
›
NGINX
nginx 中,如何 rewrite 使其$host 带上指定端口?
icemanpro
·
Aug 17, 2022
· 2856 views
This topic created in 1546 days ago, the information mentioned may be changed or developed.
也就是访问
http://www.aa.com/?a=b
实际是访问
http://www.aa.com:7777/?a=b
rewrite
Nginx
host
端口
3 replies
•
2022-08-17 14:22:57 +08:00
ZE3kr
Aug 17, 2022 via iPhone
1
proxy_pass 就行
DsuineGP
Aug 17, 2022
2
需求没表述清楚
- 如果需要是浏览器重定向,就 rewrite 301 或者 302
- 如果需要的是反代,实际上你需要的是 proxy_pass
gqkkk
Aug 17, 2022
3
upstream 里定义
http://nginx.org/en/docs/http/ngx_http_upstream_module.html
About
·
Help
·
Advertise
·
Blog
·
API
·
FAQ
·
Privacy
·
Solana
·
2417 Online
Highest 6679
·
Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 29ms ·
UTC 04:51
·
PVG 12:51
·
LAX 20:51
·
JFK 23:51
♥ Do have faith in what you're doing.
❯