在我的nginx配置中,如果我有以下设置,每当我进入该网站时,我都会得到这个网页有一个重定向循环'
server {
listen 80;
merge_slashes off;
server_name domain.com www.domain.com
rewrite ^(.*) https://$host$1 permanent;
}
server {
listen 443;
merge_slashes off;
server_name domain.com www.domain.com;
location / { try_files $uri @app; }
location @app {
include uwsgi_params;
uwsgi_pass 0.0.0.0:5002;
}
}
答案 0 :(得分:0)
尝试添加:
ssl on;
ssl_certificate /xxx/bundle.pem;
ssl_certificate_key /xxx/server.key;