Springboot Fight the war package and deploy to Tomcat run

Source: Internet
Author: User

First, modify the Pom.xml.

1. Packaging changed to War

2. Build node add <finalName> your project name </finalName>

Second, modify the project start class, inherit Springbootservletinitializer, rewrite the Configure method.

  

Three, packaging. The war file is generated under the project path target directory.

1. Idea, double-click the package in Maven view

  

2. Eclipse, right-click the project name | Run as | Maven Install

  

3. Command line, go to project path, run MVN package or mvn install

Iv. deploy to Tomcat.

Copy the resulting war package into Tomcat's WebApp directory, launch Tomcat, browser access localhost:[port number/[Project name-finalname node content in pom file]

Attached: To start Tomcat you need to build a Tomcat runtime environment: Install JDK, configure Tomcat environment variables

  

Springboot Fight the war package and deploy to Tomcat run

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.