.net core mvc 跳转LoginPath时端口缺失
在使用nginx部署.net core mvc的程序时,假如我使用的是5002端口,并且当访问站点时如果未登录,则跳转到登录页面。可是最后却发现跳转的时候端口丢失了,那是因为我配置的是
proxy_set_header Host $host;
替换为下面就好了
proxy_set_header Host $host:$server_port;
原文链接 :https://www.xiandanplay.com/
在使用nginx部署.net core mvc的程序时,假如我使用的是5002端口,并且当访问站点时如果未登录,则跳转到登录页面。可是最后却发现跳转的时候端口丢失了,那是因为我配置的是
proxy_set_header Host $host;
替换为下面就好了
proxy_set_header Host $host:$server_port;
原文链接 :https://www.xiandanplay.com/