1, first you want to make sure that you have an external network IP address. If you assign a local area network IP address, you need to go through a series of conversions to an extranet IP address, and then proceed to the following operation.
2, get the external network IP address, the configuration of Tomcat Server.xml file. The following three places are mainly configured (the Tomcat version number used for this configuration is 7.0.30)
1) <connector port= "protocol=" http/1.1 "connectiontimeout=" 20000 "redirectport=" 8443 "/> Change port port to 80, HTTP-based protocols are typically accessed via 80 ports, which avoids the hassle of entering 8080 each time.
2) <engine name= "Catalina" defaulthost= "192.168.1.2" > To change the defaulhost localhost to your own extranet IP address, provided for outside access.
3)
<context path= "test" docbase= "D:/sudentmanager" reloadable= "true" crosscontext= "true" ></Context> host Name to the external IP address, while adding a context tag in the tag, the contents as above, path represents the virtual path of Access, Docbase represents the actual project path.
With the configuration of the above three steps, the configuration of the server has been implemented. We can start Tomcat, where the project can be accessed directly via an IP address.
The above methods are fully adapted to local area network use.
Make your own computer server publish Tomcat Project Extranet access