Application with JBOSS Wildfly respond through DNS

0

I'm extremely beginner in this environment setup part and need to put an application that I developed into production. I already have a registered domain and I would like the user, instead of typing IP: 8080 / APR, could enter the domain of the application. It turns out that I have no idea how to do this in Jboss, I've done it before in IIS and the configuration is usually very simple. I circled the internet behind it, but to no avail. Does anyone have any idea where I set this up?

I'm using Jboss Wildfly 10, the application is in Java with Spring and I'm uploading the server in standalone mode.

Any help is welcome. Thank you.

    
asked by anonymous 25.04.2018 / 17:13

2 answers

2

You need the jboss configuration in the WEB-INF folder of your project. For Wildfly to recognize the path (other than default), add the following tag <context-root> followed by the prefix you want to be in front of your application, how you want it to run in root just add /

WEB-INF / jboss-web.xml

<?xml version="1.0"?>
<jboss-web>
   <context-root>/</context-root>

  <!-- outras configs do projeto -->
</jboss-web>
    
25.04.2018 / 19:06
0

In addition to the one suggested by Paulo H. Hartmann, I also changed my standalone.xml to the following:

<host name="default-host" alias="localhost, myAppDomain.com" default-web-module="myApp.war">
    <location name="/" handler="welcome-content"/>
    <filter-ref name="server-header"/>
    <filter-ref name="x-powered-by-header"/>
</host>

With this configuration, I can also access my application through DNS.

    
26.04.2018 / 15:52