creating new project: create a Spring Boot application, which can be done in a number of ways. The easiest is to go to https://start.spring.io and generate an empty project (choosing the “Web” dependency as a starting point).
Add a Home Page: In your new project, create index.html in the src/main/resources/static folder.\
Securing the Application with GitHub and Spring Security: To make the application secure, you can simply add Spring Security as a dependency. Since you’re wanting to do a “social” login (delegate to GitHub), you should include the Spring Security OAuth 2.0 Client starter.
Add a New GitHub App: To use GitHub’s OAuth 2.0 authentication system for login, you must first Add a new GitHub app. Select “New OAuth App” and then the “Register a new OAuth application” page is presented. Enter an app name and description. Then, enter your app’s home page, which should be http://localhost:8080, in this case. Finally, indicate the Authorization callback URL as http://localhost:8080/login/oauth2/code/github and click Register Application.