GlassFish does not get root context of the application

3

EDIT Galera I got to solve, I was missing pointing my application to my virtual server, thank you.

I uploaded an application on the server today and glassFish is not picking up the application context alone for example to access I'm having to put: www.blabla.com/Trend .

<glassfish-web-app>
<context-root>/Atendimento</context-root>

<parameter-encoding default-charset="UTF-8" />

<property name="alternatedocroot_1" value="from=/backgrounds/* dir=e:\HRatendimento\imagens\" />
<property name="alternatedocroot_2" value="from=/logos/* dir=e:\HRatendimento\imagens\" />
<property name="alternatedocroot_3" value="from=/gerais/* dir=e:\HRatendimento\imagens\" />
<property name="alternatedocroot_4" value="from=/anexos/* dir=e:\HRatendimento\imagens\" />
<property name="alternatedocroot_5" value="from=/usuarios/* dir=e:\HRatendimento\imagens\" />
<property name="alternatedocroot_6" value="from=/licenca/* dir=e:\HRatendimento\" />
<property name="alternatedocroot_7" value="from=/manuais/* dir=e:\HRatendimento\" />

And in glassFish I left contextRoot as /Atendimento .

Does anyone have any idea what it might be?

    
asked by anonymous 29.01.2015 / 14:28

1 answer

3

In GlassFish the root synonym is / .

You can set this context in several ways:

  • By configuration files like glassfish-web.xml :

    <glassfish-web-app>
        <context-root>/</context-root>
    </glassfish-web-app>
    
  • By admin console as shown in your question.
  • By asadmin at the time of publishing your application:

     asadmin deploy --contextroot "/" Atendimento.war
    
  • From your IDE (usually there is an option to change the context-root in the deploy settings).
  • 29.01.2015 / 15:09