Step 7: How To Download And Configure SonarQube.
Recommended Article: How To Install And Run SonarQube On Centos 7 \qĪnd use the following command to exit from the “postgres” user. Run the command below to exit from the psql shell.
It is time to set a password for the newly created user for the SonarQube database: ALTER USER sonar WITH ENCRYPTED password ' ?Qn4' Īlso, create a new database for the PostgreSQL database.
To create a new user, run: createuser sonar To switch to the Postgres user: su - postgres Use the command below to change the default password of the Postgres user. Then, check service status and start it by typing: systemctl status postgresql-10 systemctl start postgresql-10 Now, you need to enable PostgreSQL on system boot to be able to start service and set on boot: systemctl enable postgresql-10 Then, modify pg_hba.conf file change “peer” to “ trust” and “idnet” to “md5”. To initialize the database, use: /usr/pgsql-10/bin/postgresql-10-setup initdb Note: In case you need to see downloads for Redhat based distributions, check the .Īnd to install the server: yum install postgresql10-server postgresql10-contrib
Run the command below to install the repository: yum install Now, you can check the java version and then save and exit the file. Next, you should add java environment variables: vim /etc/bashrcĪdd the following lines to the end of the file: export JAVA_HOME=/usr/java/jdk-11.0.5/ export JRE_HOME=/usr/java/jdk-11.0.5/jre PATH=$PATH:$HOME/bin:$JAVA_HOME/bin You can find the Java location after the installation by typing: cd /usr/java/ Note: You can use the following command as the alternative command if the “wget” command is not available in your system to install it. Second, go to your server and download by typing: wget Otherwise, act like the below paths:įirst, copy the download link from web browser downloads. You can also download the rpm package to your machine and upload it to the sonar server. Consider that if you have an account, use it, or create a new one. It will redirect to the oracle login before you download. In case you have not installed Oracle Java 11, Download it from here. Use the following command to install it: yum install vim -yįirst, edit “nf” file: vim /etc/nfĪnd then, add the following lines: vm.max_map_count=262144 fs.file-max=65536 You can install vim if you found it is not available yet. Step 3: How To Set hostname To The Server vim /etc/hostname You need to open the SELinux configuration and edit the file: vim /etc/sysconfig/selinuxĪnd to continue you should change “SELINUX=enforcing” to “SELINUX= disabled”.
Run the below command to update the system using the root user: yum update To start you need to systems setting for Linux. Have a look at them below:ħ- Comments Tutorial Install And Run SonarQube On Centos 7Ĭontinue with this guide to learn how to install a tool that is ready to fit with your existing tools to help you when the quality or security of your codebase is at risk.
Sonar covers the 7 sections of code quality. Let’s see the benefits of this web-based platform that is made to measure and analyze the source code quality.ħ- Enable Continuous Code Quality ManagementĨ- Define And Increment Requirements Efficientlyġ0- Reduce Risk with Vendor Support and Services Code Quality Covering Tutorial Install And Run SonarQube On Centos 7.
However, you can use the Critical Patch Update (CPU) releases.Īdditionally, you can check the official document for complete information. Also, it is able to analyze any kind of Java source files regardless of the version of Java they comply with. Versions beyond Java 11 are not officially supported. Note: SonarQube scanners require version 8 or 11 of the JVM and the SonarQube server requires version 11. To let this tutorial work better, please consider the below Prerequisites:Ģ- At least 2GB of RAM to run efficiently.ģ- database Mysql or PostgreSQL or Mariadb as per your environment. Buy your own CentOS VPS 7 Server to have a real experience with this quality system development tool. SonarQube is an open-source platform tool that helps you to manage the quality of source code, code analysis, etc. Let’s learn about this most widely used tool for code coverage and analysis. Learn how To Install And Run SonarQube On Centos 7 Linux Server.