如何让我的一个域名支持Http & Https 协议,都是用同一个目录?
Http
Https
光阴似箭催人老,日月如移越少年。
<VirtualHost *:443> ServerName example.com DocumentRoot /var/www/html ... SSL相关部分 ... </VirtualHost> <VirtualHost *:80> ServerName example.com DocumentRoot /var/www/html ... 其他apache配置 ... </VirtualHost>
Isn’t that right? I haven't tried it either, just looked at the configuration I'm using.
ServerName example.com:443 DocumentRoot /var/www/html ... SSL related parts ... ServerName example.com:80 DocumentRoot /var/www/html ... Other apache configuration ...
Isn’t that right? I haven't tried it either, just looked at the configuration I'm using.
ServerName example.com:443
DocumentRoot /var/www/html
...
SSL related parts
...
ServerName example.com:80
DocumentRoot /var/www/html
...
Other apache configuration
...