Spring Boot 打 war 包的步骤
2021-07-05 14:07
阅读:854
标签:uil lse ted group `` VID depend err artifact
## Spring Boot 打 war 包的步骤
1. 添加 spring-boot-start-tomcat 的 provided 依赖
```
spring-boot-starter-tomcat
```
2. 添加 maven-war-plugin 插件
```
maven-war-plugin
```
3. 继承 SpringBootServletInitializer, 重写 config 方法
```
@Override
protected SpringApplicationBuilder configure(SpringApplicationBuilder builder) {
return builder.sources(MainApplication.class);
}
```
Spring Boot 打 war 包的步骤
标签:uil lse ted group `` VID depend err artifact
原文地址:https://www.cnblogs.com/facous/p/9597202.html
文章来自:搜素材网的编程语言模块,转载请注明文章出处。
文章标题:Spring Boot 打 war 包的步骤
文章链接:http://soscw.com/index.php/essay/102080.html
文章标题:Spring Boot 打 war 包的步骤
文章链接:http://soscw.com/index.php/essay/102080.html
评论
亲,登录后才可以留言!