Skip to content
This repository was archived by the owner on Jan 30, 2023. It is now read-only.

Commit ea3d055

Browse files
committed
Fixed the vesion of sonarqube and postgres images; updated alpine and added README.
1 parent 87eb850 commit ea3d055

File tree

3 files changed

+28
-4
lines changed

3 files changed

+28
-4
lines changed

README.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
# sonarqube-scala-docker
2+
A docker-compose recipe for out-of-the-box [SonarQube LTS](https://www.sonarqube.org) instance with support for [Scala](http://www.scala-lang.org), [Scoverage](https://github.com/scoverage/scalac-scoverage-plugin) (code coverage metrics) and [Scalastyle](http://www.scalastyle.org) + [Scapegoat](https://github.com/sksamuel/scapegoat) (static code analysis). :sunglasses:
3+
4+
5+
## Usage
6+
To start SonarQube in a daemon mode, simply run:
7+
8+
```bash
9+
docker-compose up -d
10+
```
11+
12+
Once docker pulls all the required images and starts up the containers, the application should become available on [http://localhost](http://localhost). The default SonarQube login details for the Administrator account are `admin:admin`.
13+
14+
15+
## Dependencies
16+
* [SonarQube 5.6.7 LTS](https://hub.docker.com/_/sonarqube)
17+
* [PostgreSQL 9](https://hub.docker.com/_/postgres)
18+
* External SonarQube plugins:
19+
* [Sagacify/sonar-scala](https://github.com/Sagacify/sonar-scala) - provides support for scalastyle and scoverage.
20+
* [arthepsy/sonar-scala-extra](https://github.com/arthepsy/sonar-scala-extra) - adds scapegoat inspections.
21+
22+
23+
## License
24+
The project is licensed under the Apache License v2. See the [LICENSE file](LICENSE) for more details.

docker-compose.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ version: "2"
22

33
services:
44
sonarqube:
5-
image: sonarqube:lts
5+
image: sonarqube:5.6.7-alpine # lts
66
ports:
77
- "80:9000"
88
networks:
@@ -13,7 +13,7 @@ services:
1313
- plugins
1414

1515
db:
16-
image: postgres
16+
image: postgres:9 # sonarqube 5 isn't compatible with postgres 10
1717
networks:
1818
- sonarnet
1919
environment:

plugins/Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
FROM alpine:3.4
1+
FROM alpine:3.6
22

3-
RUN apk --no-cache add --repository http://dl-cdn.alpinelinux.org/alpine/3.4/community wget ca-certificates
3+
RUN apk --no-cache add --repository http://dl-cdn.alpinelinux.org/alpine/3.6/community wget ca-certificates
44

55
WORKDIR /tmp/sonarqube/plugins
66
RUN wget https://github.com/Sagacify/sonar-scala/releases/download/v0.0.3/sonar-scala-plugin-0.0.3.jar

0 commit comments

Comments
 (0)