两个坑
.war.original 生成这种格式的文件,是因为在开启了二次打包。具体可以看
修改入口文件的配置 , 官方文档看
类似下面的代码,要继承SpringBootServletInitializer
@SpringBootApplicationpublic class Application extends SpringBootServletInitializer { @Override protected SpringApplicationBuilder configure(SpringApplicationBuilder application) { return application.sources(Application.class); } public static void main(String[] args) throws Exception { SpringApplication.run(Application.class, args); }}