spring_boot 发布成war包 ,部署到外部的tomcat
来源:互联网 发布:股票软件编程 编辑:程序博客网 时间:2024/06/04 18:14
由jar变成war
- 1
- 1
如果是上面的打包方式,启动方式则为
- 1
- 2
- 1
- 2
改变成war
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
只需要把tomcat的范围改成provided
如果要发布到外部的tomcat同时需要改变启动方式
新增ServletInitializer类
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 11
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 11
Application.class 为标注有@SpringBootApplication的主启动类
注意的问题
此时打成的包的名称应该和application.properties的
server.context-path=/spring-boot
保持一致
- 1
- 2
- 3
- 1
- 2
- 3
如果不一样发布到tomcat的webapps下上下文会变化
0 0
- spring_boot 发布成war包 ,部署到外部的tomcat
- spring_boot 发布成war包 ,部署到外部的tomcat
- spring_boot 发布成war包 ,部署到外部的tomcat
- spring_boot 发布成war包 ,部署到外部的tomcat
- spring_boot 发布成war包 ,部署到外部的tomcat
- spring boot发布war包,部署到外部tomcat服务器
- Spring boot发布成war包,可部署到tomcat
- 部署WAR包到TOMCAT的方法
- war包部署到tomcat
- 部署war包到tomcat
- 部署war包到Tomcat
- 部署war包到Tomcat
- 部署war包到tomcat
- 【Tomcat】部署war包到tomcat
- Spring Boot教程 - 6. 打包成可部署到外部servlet容器的war包
- war包发布到tomcat中遇到的问题
- Jenkins部署war包到远程tomcat的webapps下
- Jenkins部署war包到远程tomcat的webapps下
- Spring项目使用JUnit4进行测试
- (function($){...})(jQuery)是什么意思
- 设计模式-原型模式
- 集成支付宝支付
- Java中的24种设计模式与7大原则
- spring_boot 发布成war包 ,部署到外部的tomcat
- item-note左右对齐
- Struts2学习
- Dagger2学习笔记之配置
- matlab合并向量;;
- 设置UICollectionViewCell选中颜色
- react+redux构建淘票票首页
- Java Jtable用法总结
- scala 替换段落中的多个空格、换行、制表符