Upgrade & Secure Your Future with DevOps, SRE, DevSecOps, MLOps!

We spend hours scrolling social media and waste money on things we forget, but won’t spend 30 minutes a day earning certifications that can change our lives.
Master in DevOps, SRE, DevSecOps & MLOps by DevOpsSchool!

Learn from Guru Rajesh Kumar and double your salary in just one year.


Get Started Now!

Sonarqube: SonarQube Basic Workflow using Scanner CLI

In Workstation

Step 1 – Install Java

$ sudo apt update
$ sudo apt install openjdk-17-jdk
$ sudo apt install openjdk-17-jre
$ java –version

Step 2 – Download a Scanner

$ wget https://binaries.sonarsource.com/Distribution/sonar-scanner-cli/sonar-scanner-cli-7.1.0.4889-linux-x64.zip
$ sudo apt install unzip
$ unzip sonar-scanner-cli-7.1.0.4889-linux-x64.zip
$ unzip sonar-scanner-cli-7.1.0.4889-linux-x64.zip
$ mv sonar-scanner-7.1.0.4889-linux-x64 sonar-scanner

Step 3 – Download the source code

$ git clone https://github.com/devopsschool-demo-labs-projects/java-sonarqube-helloworld-src.git

Step 4 – Configure a scanner

$ cd sonar-scanner
$ cd conf
$ vi sonar-scanner.properties

sonar.host.url=http://3.109.214.5:9000/
sonar.login=squ_a428a75a14d702d278f56e6eda2801f74e7916ec

Step 5 – Run the scanner on the source coce

$ cd java-sonarqube-helloworld-src
$ vi sonar-project.properties
$ /home/ubuntu/rajesh/sonar-scanner/bin/sonar-scanner

Subscribe
Notify of
guest
0 Comments
Newest
Oldest Most Voted
Inline Feedbacks
View all comments

Certification Courses

DevOpsSchool has introduced a series of professional certification courses designed to enhance your skills and expertise in cutting-edge technologies and methodologies. Whether you are aiming to excel in development, security, or operations, these certifications provide a comprehensive learning experience. Explore the following programs:

DevOps Certification, SRE Certification, and DevSecOps Certification by DevOpsSchool

Explore our DevOps Certification, SRE Certification, and DevSecOps Certification programs at DevOpsSchool. Gain the expertise needed to excel in your career with hands-on training and globally recognized certifications.

0
Would love your thoughts, please comment.x
()
x