This is the backend readme for the Krisefikser project.
Before running the application, you need to set up your environment variables in a .env file. Ask the developer team for the file, then add it to the root directory of the project.
Look in the .env.example file that lies at the root of the project.
If you have Docker installed on your machine, start Docker in a logged out mode and then run:
docker compose up --buildNote: First build may take some time (approximately five minutes or more)
To stop the container:
docker compose downTo run the backend directly:
mvn clean install
mvn spring-boot:runTo run the tests:
mvn clean testFor test coverage report:
mvn jacoco:reportThe coverage report can be found at target/site/jacoco/index.html and can be opened in any
browser.
To connect to the database, make sure you've properly configured the database URL, username, and password in your .env file.
The backend follows a standard Spring Boot application structure:
- krisefikser - Main source code
- resources - Application configuration
- test - Test cases
If you encounter any issues:
- Ensure your .env file is correctly configured
- Check database connectivity
- Verify you're using the correct Java version (17 or newer)
- Make sure all required dependencies are installed