1.修改启动类
1 @SpringBootApplication 2 @MapperScan("com.wm.springboot.dao") 3 public class SpringbootApplication extends SpringBootServletInitializer { 4 5 @Override 6 protected SpringApplicationBuilder configure(SpringApplicationBuilder builder) { 7 return super.configure(builder.sources(SpringbootApplication.class)); 8 } 9 10 public static void main(String[] args) { 11 SpringApplication.run(SpringbootApplication.class, args); 12 } 13 14 }
2.打包
3.复制war包放到webapps中启动tomcat