Skip to content

Latest commit

 

History

History
60 lines (30 loc) · 1.56 KB

README.md

File metadata and controls

60 lines (30 loc) · 1.56 KB

Spring & Thymeleaf project


A Spring Web MVC application that renders thymeleaf templates as HTML. Supports integration with Spring Security and provides login logout support. Uses Spring Data to persist data into the MYSQL db.

NOTE: Thymeleaf is an HTML template engine that does not support PUT or DELETE HTTP methods for its method attribute.

Prerequisites


  • JDK 11 and JAVA_HOME environment variable set

Database


Install local mysql server -v 8.0.25, then create a user with credentials (you can use workbench ui) and specify spring.datasource.username and spring.datasource.password in application.properties file. On building the project, the DB should be created automatically

Building the project


Clone the repository:

git clone https://github.com/purshink/Spring-Boot-Thymeleaf-App

Navigate to the newly created folder:

cd Spring-Boot-Thymeleaf-App

Run the project with:

./mvnw clean spring-boot:run

Or on Windows:

mvnw.cmd clean spring-boot:run

Navigate to:

http://localhost:8080

Login with:

user or business,
password:topsecret

Spring Mail

Make sure to specify a valid spring.mail.username and spring.mail.password in the application.properties file in order to be able to send an Email confirmation for updating user entries.

IMPORTANT: if you decide not to specify mail credentials, you will get javax.mail.AuthenticationFailedException. The rest of the application should work normally despite this exception.