Glass fish HTTPS重定向到不同的URL

时间:2014-08-15 05:29:34

标签: ssl https glassfish-3

即时通讯使用glassfish 3.1.2.2我已将我的域名映射到我的主机文件中的“www.testdomain.com”。我的不安全文件打开如下url。

"http://www.testdomain.com:8083/index.html"

但问题是当我试图打开一个安全页面时,它会重定向到另一个网址 如下。它会在URL前面添加一些实际上是我的应用程序名称的前缀。

https://www.testdomain.com:8181/myapplicationname/securepage.xhtml

我希望我的安全页面像下面提到的网址一样打开

https://www.testdomain.com:8181/securepage.xhtml

我必须更改任何玻璃鱼设置吗?或者我该怎么做?

1 个答案:

答案 0 :(得分:0)

在玩了玻璃鱼4小时后,我终于找到了解决方案 它发生因为我在glassfish中设置我的默认应用程序。我做的是

GlassFish -> default-config -> Virtual Servers -> Server

你有"默认网络模块:"把它变成"空"

以及

GlassFish -> server-config -> Virtual Servers -> Server

并且还设置了"默认Web模块:"到"空"

然后

转到

Application -> select your deployed web application 

并制作" Context Root:"并且仅限于" /" 这解决了我的问题