Last active
December 7, 2024 03:37
-
Star
(113)
You must be signed in to star a gist -
Fork
(65)
You must be signed in to fork a gist
-
-
Save Warchant/0d0f0104fe7adf3b310937d2db67b512 to your computer and use it in GitHub Desktop.
docker-compose file to setup production-ready sonarqube
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: "3" | |
services: | |
sonarqube: | |
image: sonarqube | |
expose: | |
- 9000 | |
ports: | |
- "127.0.0.1:9000:9000" | |
networks: | |
- sonarnet | |
environment: | |
- sonar.jdbc.url=jdbc:postgresql://db:5432/sonar | |
- sonar.jdbc.username=sonar | |
- sonar.jdbc.password=sonar | |
volumes: | |
- sonarqube_conf:/opt/sonarqube/conf | |
- sonarqube_data:/opt/sonarqube/data | |
- sonarqube_extensions:/opt/sonarqube/extensions | |
- sonarqube_bundled-plugins:/opt/sonarqube/lib/bundled-plugins | |
db: | |
image: postgres | |
networks: | |
- sonarnet | |
environment: | |
- POSTGRES_USER=sonar | |
- POSTGRES_PASSWORD=sonar | |
volumes: | |
- postgresql:/var/lib/postgresql | |
- postgresql_data:/var/lib/postgresql/data | |
networks: | |
sonarnet: | |
volumes: | |
sonarqube_conf: | |
sonarqube_data: | |
sonarqube_extensions: | |
sonarqube_bundled-plugins: | |
postgresql: | |
postgresql_data: |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Just my 2 cents:
The "official"
docker-compose.yml
usage example for Sonarqube with PostgreSQL can be found here.I was able to start SonarQube v10 + PostgreSQL v15.3 on a Windows 11 machine with the following
docker-compose.yml
file.Edit: The alternative for
SONAR_ES_BOOTSTRAP_CHECKS_DISABLE=true
seems to be the following:Create (or edit) the file
%USERPROFILE%\.wslconfig
.Add the following:
docker-compose.yml
: