To publish the project to tomcat in a way

: 1. Mode 1 relative path under the project index.html on the tomcat webapps / ROOT, browser access to the address: http: //www.aaa.com: 8080 / index.html

2. Relative Path Method 2: New aaa file in the webapps folder, and then put the project index.html folder, visit the address: http: //www.aaa.com: 8080 / aaa

3. Virtual Path Method 1: find server.xml in the tomcat's conf configuration folder,

  找到<Host name="localhost" appBase="webapps" unpackWARs="true" autoDeploy="true">下,

  New <Context docBase = "D: \ xml" path = "/ bbb"> </ Context>, save and exit.

  Then create a new xml folder under the D drive, the project index.html put this folder.

  Browser to access the address: http: //www.aaa.com: 8080 / bbb / index.html

Virtual path 4. Embodiment 2:

  a: In the tomcat conf / catalina / localhost ccc.xml file folder (custom CCC),

  b: Add the content ccc.xml

    <?xml version="1.0" encoding="UTF-8"?>

    <Context docBase="D:\xml"></Context>

  c: to put the project index.html D: / xml under

  Browser to access the address: http: //www.aaa.com: 8080 / ccc / index.html

Guess you like

Origin www.cnblogs.com/ayeex/p/11622080.html