Sign inSign up

marcosstefani/sonar

By marcosstefani

Updated over 2 years ago
Archived

Image
0

56

marcosstefani/sonar repository overview

SonarQube Custom Configuration

This Docker image extends the official SonarQube 10.3.0 Community edition image, providing a customized configuration through environment variables and a sonar.properties file.

Objective

The purpose of this project is to offer a SonarQube Docker image with pre-configured settings, allowing users to quickly set up SonarQube instances with a PostgreSQL database.

Environment Variables

The following table lists the environment variables used in this Docker image and their respective descriptions:

VariableDescription
DATABASE_USERNAMEUsername for the PostgreSQL database.
DATABASE_PASSWORDPassword for the PostgreSQL database.
DATABASE_HOSTHostname or IP address of the PostgreSQL server.
DATABASE_PORTPort number for the PostgreSQL server.
DATABASE_NAMEName of the PostgreSQL database.

Custom Configuration

The Dockerfile copies a custom sonar.properties file to the SonarQube configuration directory (/opt/sonarqube/conf). Users can modify this file to further customize their SonarQube setup based on specific requirements.

Example Usage

docker run -p 9000:9000
           -e DATABASE_USERNAME=myuser \
           -e DATABASE_PASSWORD=mypassword \
           -e DATABASE_HOST=db.example.com \
           -e DATABASE_PORT=5432 \
           -e DATABASE_NAME=mydatabase \
           marcosstefani/sonar:1.0.0

Make sure to replace the placeholder values (myuser, mypassword, db.example.com, 5432, mydatabase) with your actual database credentials and connection details.

License

This project is licensed under the MIT License.

Tag summary

Content type

Image

Digest

sha256:3d16adca6

Size

460.6 MB

Last updated

over 2 years ago

docker pull marcosstefani/sonar:1.0.0