2016-07-25 68 views
-1

我愿做一个端口转发.htaccess的像以下情形:的.htaccess重写规则到web服务器,而不改变URL

https://example.com    => http://getcontent.from:8080 
https://example.com/test   => http://getcontent.from:8080/test 
https://example.com/favicon.ico => http://getcontent.from:8080/favicon.ico 
https://example.com/img/asdf.png => http://getcontent.from:8080/img/asdf.png 

但是URL应该始终处于“example.com”。

主要目标是转发到不同服务器上的节点服务器,因为我没有https。

+0

所以只需要清楚https://example.com将重定向到http://getcontent.from:8080,但浏览器中的URL将显示https://example.com? – error2007s

+0

@ error2007s是的 – ReeCube

回答

0

您可以使用brontobytes中的示例#2,只需更改端口即可。