请问一下关于nginx反向代理的问题 #3758
Replies: 6 comments 1 reply
-
回下自己
|
Beta Was this translation helpful? Give feedback.
-
6c2f348 |
Beta Was this translation helpful? Give feedback.
-
同样根据文档配置nginx的子目录反代,通过 |
Beta Was this translation helpful? Give feedback.
-
最近成功配置子目录 |
Beta Was this translation helpful? Give feedback.
-
根据你给出的信息来看
|
Beta Was this translation helpful? Give feedback.
-
不想用子目录也可以二级域名 server {
listen 80; #监听80
server_name xxx.xxx.com; #二级域名访问
location / {
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header Host $http_host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header Range $http_range;
proxy_set_header If-Range $http_if_range;
proxy_redirect http://xxx.xxx.com:5244/ /; #反代二级域名
proxy_pass http://127.0.0.1:5244/;
# the max size of file to upload
client_max_body_size 20000m;
}
} 记得解析 |
Beta Was this translation helpful? Give feedback.
-
通过nginx转发之后,直接用80访问就显示这样↓↓↓,打不开主页
根据官网的反向代理教程改了etc/alist/config.json:
"port": 5244,
"site_url": "/alist",
nginx.conf也改了:
现在情况就是,内外网都能通过5244访问,80打不开,请问下配置文件有问题没?
Beta Was this translation helpful? Give feedback.
All reactions