raymond9zhou / frps-nginx-https

nginx反代frps实现https的模板配置文件
https://blog.ray8.cc/archives/frpc-frps-nginx-real-ip-https-rewrite-ssl-cert-pure-code.html
MIT License
41 stars 8 forks source link

case2 里关于访问域名后仍然带端口号的问题 #1

Open MEZboy opened 5 years ago

MEZboy commented 5 years ago

第一种是: proxy_set_header Host $host;

第二种是: proxy_set_header Host $host:$server_port;

在访问https域名的时候,个别域名都会在结尾带上端口号

image

image

不知道有没有好的解决方案

raymond9zhou commented 5 years ago

抱歉前一段时间因为忙于开发没有顾得上GitHub的动态,出现端口号是因为后端没有配置https而采用http导致的,我这里的设计理念是为了优化用户体验,避免直接给用户抛出一个异常。如果确实需要隐藏端口可以为单独域名配置server段。

MEZboy commented 5 years ago

原来如此,了解了,谢谢,但是现在有另外一个情况,就是我现在远程frps服务端那个nginx,现在配置不通过frps的站点,比如maven私服,好像不会生效了,有可能是自己的问题,正在排查

forvoid commented 2 years ago

谢谢大佬 解决了我nginx https 转发https 端口的问题。case2 。牛皮