This is a simple blog application built with Spring Boot, featuring authentication and post management functionalities.
- User registration and authentication
- Creating, reading, updating, and deleting posts
- JSON Web Token (JWT) based authentication
- RESTful API for post management
- Spring Boot
- Spring Security
- Spring Data JPA
- H2 Database (for development)
- Mockito & JUnit (for testing)
- Maven
To get started with the project, follow these steps:
-
Clone the repository:
git clone https://github.com/MohamedHamed12/blog_spring_boot.git
-
Navigate to the project directory:
cd blog_spring_boot
-
Build the project using Maven:
mvn clean install
-
Run the application:
java -jar target/blog-application.jar
-
Access the application at http://localhost:8080
- The application uses an H2 in-memory database by default for development.
- You can configure the database settings in the
application.properties
file. - Security configurations are defined in the
SecurityConfiguration
class. - Adjust the configurations as needed for your environment.
-
Unit tests and integration tests are provided in the
src/test
directory. -
You can run tests using the following command:
mvn test
Contributions are welcome! If you find any issues or have suggestions for improvements, feel free to open an issue or submit a pull request.
This project is licensed under the MIT License - see the LICENSE file for details.