|
1 | 1 | # Spring Boot Starter Project
|
2 | 2 |
|
3 |
| -This project is a starter project for Spring Boot Developers. It contains technologies as Spring Boot, Hibernate, |
4 |
| -Liquibase, JPA and JWT Token Authorization. |
| 3 | +This is a starter project for Spring Boot Developers. It contains technologies as Spring Boot, Hibernate, |
| 4 | +Liquibase, JPA and Spring Security with JWT Token Authorization. |
| 5 | + |
5 | 6 |
|
6 | 7 | ## Running the project
|
7 | 8 |
|
8 | 9 | 1. Create database with name **test**
|
9 | 10 | 2. Open terminal and navigate to your project
|
10 |
| -3. Type command **mvn** |
11 |
| - |
12 |
| -## Authentication route |
| 11 | +3. Type command **mvn install** |
| 12 | +4. Type command **mvn spring-boot:run** |
13 | 13 |
|
14 |
| -Link: http://localhost:8080/auth/authenticate <br /> |
15 |
| -Method: __POST__ <br /> |
16 |
| -Data: ```{ username: "admin", password: "admin" }``` |
17 | 14 |
|
18 | 15 | ## Check application running state
|
19 | 16 |
|
20 |
| -Link: http://localhost:8080/ |
| 17 | +Route: **http://localhost:8080/** |
| 18 | + |
| 19 | + |
| 20 | +## Available profiles |
| 21 | + |
| 22 | +- Development profile (dev) |
| 23 | +- Production profile (prod) |
| 24 | + |
| 25 | + |
| 26 | +## Authentication |
| 27 | + |
| 28 | +Route: **/auth/authenticate** |
| 29 | +Method: **POST** |
| 30 | +Content-Type: **application/json** |
| 31 | +Request payload: `{ username: "admin", password: "admin" }` |
| 32 | +Response: `{ id_token: "token_hash" }` |
| 33 | + |
21 | 34 |
|
22 |
| -## Packaging |
| 35 | +## Packaging for production |
23 | 36 |
|
24 |
| -Command: ```mvn -P{profile} package``` |
| 37 | +1. **mvn clean** |
| 38 | +2. **mvn -Pprod package** |
25 | 39 |
|
26 |
| -{profile}: <br><br> |
27 |
| - - dev <br> |
28 |
| - - prod |
29 | 40 |
|
| 41 | +## Author |
30 | 42 |
|
31 |
| -_Written by Heril Muratović._ |
| 43 | +Heril Muratović |
| 44 | +Software Engineer |
| 45 | +<br> |
| 46 | +**Mobile**: +38269657962 |
| 47 | +**E-mail**: hedzaprog@gmail.com |
| 48 | +**Skype**: hedza06 |
| 49 | +**Twitter**: hedzakirk |
| 50 | +**LinkedIn**: https://www.linkedin.com/in/heril-muratovi%C4%87-021097132/ |
| 51 | +**StackOverflow**: https://stackoverflow.com/users/4078505/heril-muratovic |
0 commit comments