You should have a standard loader:
@SpringBootApplication
public class MyDemoApplication {
public static void main(String[] args) {
SpringApplication.run(MyDemoApplication.class, args);
}
}
and implement a CommandLineRunner interface with @Component annotation
@Component
public class MyRunner implements CommandLineRunner {
@Override
public void run(String... args) throws Exception {
}
}
@EnableAutoConfiguration will do the usual SpringBoot magic.
UPDATE:
As @jeton suggests the latest Springboot implements a straight:
spring.main.web-application-type=none
spring.main.banner-mode=off
See docs at 72.2