- Clone the repository using
git clone https://github.com/urosdragojevic/RealBookStore.git - Run the application using Maven
- See SonarQube setup section for instructions on running SonarQube for code analysis tasks
Project uses Java 17.
-
Install Docker and Docker Compose (Docker Desktop for Windows/Mac machines)
-
Run
docker compose upin the root of the project to start SonarQube container (docker compose up -dto start the containers in the background) -
After the containers are started, log into SonarQube at
http://localhost:9000with username:admin, password:admin.
In general, it is best practice to set an expiry on access tokens, but since this is just a local instance of Sonar it is not mandatory.
- Copy the generated token and save it as
SONAR_TOKEN=sqa_7258ae10fb0e029a908b1fcbc385bb7da40cdae1environment variable
If using IntelliJ you can specify the environment variable by editing the Run configuration of the
sonar:sonartask.
Run configuration that can be used in IntelliJ for
sonar:sonartask is stored in the.runfolder.
- Run the
sonar:sonartask. Once it completes you can access the RealBookStore project in SonarQube and check the code analysis results.


