package com.app;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.CommandLineRunner;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
import org.springframework.context.annotation.Lazy;

import com.app.Service.AuthUserService;

@SpringBootApplication
public class SlcApplication extends SpringBootServletInitializer implements CommandLineRunner {

	@Autowired
	@Lazy
	AuthUserService userService;

	public static void main(String[] args) {
		SpringApplication.run(SlcApplication.class, args);
	}

	@Override
	public void run(String... args) throws Exception {
		// TODO Auto-generated method stub

		userService.createAdmin();

	}

}
