- Clone the repository:
git clone https://github.com/your-username/project.git
- Navigate to the project directory:
cd project
- Install the required dependencies:
- If you're using Maven:
mvn install
- If you're using Gradle:
gradle build
- If you're using Maven:
- Configure the application properties:
- Open the
application.properties
file. - Set the necessary database connection properties.
- Configure JWT properties such as secret key and expiration time.
- Save the file.
- Open the
- Run the application:
- If you're using Maven:
mvn spring-boot:run
- If you're using Gradle:
gradle bootRun
- If you're using Maven:
- The application should now be running locally at
http://localhost:8080
. - Access the API documentation at
http://localhost:8080/api-docs
for details on available endpoints and how to use them.
- To access the API endpoints that require authentication, you need to obtain a JWT token.
- Make POST request to
/register
to register student(for eg) - Make a POST request to the
/login
endpoint with valid credentials to receive a token. - Include the token in the
Authorization
header of subsequent requests as a Bearer token. - You can now access the protected endpoints by sending authenticated requests.
- This project also has endponits for forgot password and mail OTP.
- Unit tests: Run the following command:
- If you're using Maven:
mvn test
- If you're using Gradle:
gradle test
- If you're using Maven:
- Integration tests: Run the following command:
- If you're using Maven:
mvn integration-test
- If you're using Gradle:
gradle integrationTest
- If you're using Maven:
- Prepare the application for deployment:
- Build an executable JAR file:
- If you're using Maven:
mvn package
- If you're using Gradle:
gradle bootJar
- If you're using Maven:
- Alternatively, build a WAR file for deployment to a servlet container.
- Build an executable JAR file:
- Deploy the generated JAR/WAR file to your preferred deployment environment.
- Configure the necessary environment variables or system properties, such as database connection details and JWT properties.
- Start the application in the deployment environment.
- The application should now be accessible at the specified deployment URL.