When we access localhost: 8080/, the JBoss welcome page will always appear. If we want to directly go to our web application when accessing the root directory, we need two steps, one is to add the WEB-INF FILE command JBoss under the/jboss-web.xml/directory to register the application to the root context, and the other is to cancel the welcome page. Wildfly and JBoss earlier versions cancel the welcome page configuration.
First add a WEB-INF under the project directory jboss-web.xml:
<?xml version="1.0" encoding="UTF-8"?> <jboss-web> <context-root>/</context-root> </jboss-web>
Open $ jboss_home/standalone/configuration/standalone. xml and find the following snippet:
<server name="default-server">
Check row 4.
<location name="/" handler="welcome-content"/>
It can be guessed that it allows us to jump to the welcome page of JBoss when accessing. Therefore, delete this row.