filmov
tv
Devops | Postgresql | How to Install PostgreSQL for SonarQube on Amazon Linux2 | AWS EC2
![preview_player](https://i.ytimg.com/vi/cJ4iLD9sOkI/hqdefault.jpg)
Показать описание
SonarQube supports PostgreSQL, MySQL, MSSQL and Oracle. In this tutorial, I will use PostgreSQL as MySQL is not recommended for large instances. For using MySQL, you can only use bundled mysql-connector-java. InnoDB engine is a must in MySQL. To avoid such restrictions, I strongly recommend using PostgreSQL. Follow the steps below to install PostgreSQL.
Setup PostgreSQL 10 Database For SonarQube
amazon-linux-extras install postgresql10 vim epel -y
yum install -y postgresql-server postgresql-devel
/usr/bin/postgresql-setup --initdb
Need to change config file as shown in below
Replace Method name "peer" to "md5"
image
Enable postgresql:
systemctl enable postgresql
Start postgresql:
systemctl start postgresql
Login into Database
su - postgres
You can get into Postgres console by typing
psql
Create a sonarqubedb database
create database sonarqubedb;
Create the sonarqube DB user with a strongly encrypted password
create user sonarqube with encrypted password 'Cloud#436';
Next, grant all privileges to sonrqube user on sonarqubedb;
grant all privileges on database sonarqubedb to sonarqube
Exit the psql prompt using the following command
\q
Switch to your sudo user using the exit command
exit
Setup PostgreSQL 10 Database For SonarQube
amazon-linux-extras install postgresql10 vim epel -y
yum install -y postgresql-server postgresql-devel
/usr/bin/postgresql-setup --initdb
Need to change config file as shown in below
Replace Method name "peer" to "md5"
image
Enable postgresql:
systemctl enable postgresql
Start postgresql:
systemctl start postgresql
Login into Database
su - postgres
You can get into Postgres console by typing
psql
Create a sonarqubedb database
create database sonarqubedb;
Create the sonarqube DB user with a strongly encrypted password
create user sonarqube with encrypted password 'Cloud#436';
Next, grant all privileges to sonrqube user on sonarqubedb;
grant all privileges on database sonarqubedb to sonarqube
Exit the psql prompt using the following command
\q
Switch to your sudo user using the exit command
exit
Комментарии