-
Notifications
You must be signed in to change notification settings - Fork 0
/
sonar-compose.yaml
48 lines (46 loc) · 1.1 KB
/
sonar-compose.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
version: "3.3"
services:
sonar:
image: sonarqube:7.9.5-community
depends_on:
- sonar-db
- init
environment:
SONAR_JDBC_URL: jdbc:postgresql://sonar-db:5432/sonar
SONAR_JDBC_USERNAME: sonartest
SONAR_JDBC_PASSWORD: sonartest
sonar.web.port: 9000
volumes:
- sonarqube_data:/opt/sonarqube/data
- sonarqube_extensions:/opt/sonarqube/extensions
- sonarqube_logs:/opt/sonarqube/logs
- sonarqube_temp:/opt/sonarqube/temp
ulimits:
nproc: 131072
nofile:
soft: 8192
hard: 131072
ports:
- "9017:9000"
init:
image: bash
privileged: true
user: root
volumes:
- ./sonarqube/init.sh:/mnt/init.sh <---- replace the path
command: ["sh", "-e", "/mnt/init.sh"]
sonar-db:
image: postgres:12
environment:
POSTGRES_USER: sonartest
POSTGRES_PASSWORD: sonartest
volumes:
- postgresql:/var/lib/postgresql
- postgresql_data:/var/lib/postgresql/data
volumes:
sonarqube_data:
sonarqube_extensions:
sonarqube_logs:
sonarqube_temp:
postgresql:
postgresql_data: