sonarqube/docker-compose.yml

41 lines
993 B
YAML

---
version: '3'
services:
app:
build: .
volumes:
- ./:/app
env_file: docker.env
sonarqube-postgresql:
image: docker.bintray.io/postgres:9.6.11
container_name: sonarqube-postgresql
ports:
- 5433:5433
environment:
POSTGRES_DB: sonar
POSTGRES_USER: sonar
POSTGRES_PASSWORD: P4ssw0rd
command: -p 5433
volumes:
- sonarqube-postgresql:/var/lib/postgresql/data
sonarqube:
image: sonarqube
container_name: sonarqube
depends_on:
- sonarqube-postgresql
links:
- sonarqube-postgresql
ports:
- 9000:9000
environment:
SONARQUBE_JDBC_URL: jdbc:postgresql://localhost:5433/sonar
SONARQUBE_JDBC_USERNAME: sonar
SONARQUBE_JDBC_PASSWORD: P4ssw0rd
volumes:
- sonarqube_conf:/opt/sonarqube/conf
- sonarqube_data:/opt/sonarqube/data
- sonarqube_extensions:/opt/sonarqube/extensions
- sonarqube_bundled-plugins:/opt/sonarqube/lib/bundled-plugins