version: httpd-2.2.15-win32-x86-openssl-0.9.8m-r2.msi
虚拟网站名:testweb
配置步骤如下:
[b]1. 将如下文件拷贝到conf目录下[/b]
[img]http://dl.iteye.com/upload/attachment/234833/b3e42005-0797-3c60-bb4b-0b30649a656d.png[/img]
将如下文件拷贝到modules目录下
[img]http://dl.iteye.com/upload/attachment/234871/cd3eee97-da8a-3e11-8cf6-821f0c691f40.png[/img]
[b]2 修改httpd.conf.[/b]
2.1 开启
2.2 将<IfModule ssl_module>修改为
在最后加上引入代码
[b]3. 修改workers.properties文件[/b]
要确保jboss已经开启ajp。可查看jboss-4.2.3.GA\server\default\deploy\jboss-web.deployer(目录仅供参考)下的server.xml,
[b]4. 修改uriworkermap.properties[/b],在最末增加一行
[b]5. 修改extra/httpd-ssl.conf[/b]
在</Directory>后增加如下代码
[b]6. 重启apache[/b]
查看URL:
https://127.0.0.1
https://127.0.0.1:443
https://127.0.0.1/testweb
[b]7.如果apache不能启动[/b],则再cmd中输入 httpd -t 以检查配置是否正确
[img]http://dl.iteye.com/upload/attachment/234869/23903f13-e752-3021-88e3-bc368c7bdd16.png[/img]
[b]8.说明[/b]ca.crt,server.crt,server.key 为模拟SSL 文件,到时替换之。
虚拟网站名:testweb
配置步骤如下:
[b]1. 将如下文件拷贝到conf目录下[/b]
[img]http://dl.iteye.com/upload/attachment/234833/b3e42005-0797-3c60-bb4b-0b30649a656d.png[/img]
将如下文件拷贝到modules目录下
[img]http://dl.iteye.com/upload/attachment/234871/cd3eee97-da8a-3e11-8cf6-821f0c691f40.png[/img]
[b]2 修改httpd.conf.[/b]
2.1 开启
LoadModule ssl_module modules/mod_ssl.so
LoadModule negotiation_module modules/mod_negotiation.so
LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_ajp_module modules/mod_proxy_ajp.so
2.2 将<IfModule ssl_module>修改为
<IfModule ssl_module>
#确认引入了ssl的配置文件
Include conf/extra/httpd-ssl.conf
SSLRandomSeed startup builtin
SSLRandomSeed connect builtin
</IfModule>
在最后加上引入代码
#Include mod_jk's specific configuration file
Include conf/mod-jk.conf
[b]3. 修改workers.properties文件[/b]
# modify the host as your host IP or DNS name.
worker.node1.port=8009
worker.node1.host=127.0.0.1
worker.node1.type=ajp13
worker.node1.lbfactor=1
worker.node1.cachesize=50
要确保jboss已经开启ajp。可查看jboss-4.2.3.GA\server\default\deploy\jboss-web.deployer(目录仅供参考)下的server.xml,
<Connector port="8009" address="${jboss.bind.address}" protocol="AJP/1.3"
emptySessionPath="true" enableLookups="false" redirectPort="8443" />
<Engine name="jboss.web" defaultHost="localhost">
[b]4. 修改uriworkermap.properties[/b],在最末增加一行
/testweb|/*=loadbalancer
[b]5. 修改extra/httpd-ssl.conf[/b]
在</Directory>后增加如下代码
#enable SSLv2 ,SSLv3, TLSv1 (All)
SSLProtocol all
<Location /tp>
Allow from *
ProxyPass ajp://127.0.0.1:8009/testweb
ProxyPassReverse ajp://127.0.0.1:8009/testweb
#RedirectMatch temp .* http://localhost:8080/testweb
</Location>
[b]6. 重启apache[/b]
查看URL:
https://127.0.0.1
https://127.0.0.1:443
https://127.0.0.1/testweb
[b]7.如果apache不能启动[/b],则再cmd中输入 httpd -t 以检查配置是否正确
[img]http://dl.iteye.com/upload/attachment/234869/23903f13-e752-3021-88e3-bc368c7bdd16.png[/img]
[b]8.说明[/b]ca.crt,server.crt,server.key 为模拟SSL 文件,到时替换之。