Search code examples
javanetwork-programmingjbossjava-ee-6jboss7.x

JBoss Application Server: Accessing deployed web application from another machine


I have deployed a web application on to Jboss standalone application server Version 7.1.1.

But for some reason I am not able to access the application from another machine in same network. Server is running on port 18080.

I have deployed the same application on tomcat server which is also running on the same machine, I am able to access it remotely on other machine. port number for tomcat: 8080

To verify if the port number had some issue, I just swapped the port number between the tomcat 18080 and Jboss to 8080, I can access application from tomcat but Jboss its not accessible. Thus port number is has no issue.

I have looked a bit into Jboss server standalone.xml file and tried to change the socketBinding element's interface attribute to public, still no use.

socket-binding name="http" interface="public" port="18080"

Can anybody tell me what change I need to make so that I can access these web application deployed on Jboss be accessed remotely?


Solution

  • Alternatively, you can also define the public interface IP binding using the JBoss startup script with it's -b modifier. For example:

    To bind to an specific IP:

    ./standalone.sh -b xxx.xxx.xxx.xxx
    

    To bind to all the IPs:

    ./standalone.sh -b 0.0.0.0
    

    The default behaviour binds only to localhost (127.0.0.1).