0
此处如何将替代设置为任何地址,以便我可以在AWS Application Load Balancer中使用它。如何将http重定向到JBoss EAP 6.4中的https?
<subsystem xmlns="urn:jboss:domain:web:2.2" default-virtual-server="default-host" native="false">
<connector name="http" protocol="HTTP/1.1" scheme="http" socket-binding="http"/>
<connector name="https" protocol="HTTP/1.1" scheme="https" socket-binding="https" enable-lookups="false" secure="true" />
<virtual-server name="default-host" enable-welcome-root="true">
<rewrite pattern="^/(.*)$" substitution="https://localhost:443/$1" flags="RL">
<condition test="%{HTTPS}" pattern="off" />
</rewrite>
<alias name="localhost"/>
<alias name="example.com"/>
</virtual-server>
我要像
<rewrite pattern="^/(.*)$" substitution="https://%HOST_NAME%" flags="RL">
<condition test="%{HTTPS}" pattern="off" />
</rewrite>
它仍然重定向到** http **只,它不工作** https **。已修改** web.xml **还有 –
' <连接器名称=“https”protocol =“HTTP/1.1”scheme =“https”socket-binding =“https”enable-lookups =“false”secure =“true”> ' –