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

Commit b7d321a

Browse files
authored
Upgrade sonar-scala to 6.8.0 LTS. (#9)
1 parent 8dc4460 commit b7d321a

File tree

9 files changed

+99
-28
lines changed

9 files changed

+99
-28
lines changed

.circleci/config.yml

+35
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,30 @@ jobs:
4040
./release.sh
4141
git tag -a $VERSION -m "Release $VERSION."
4242
git push --tags
43+
release-lts:
44+
docker:
45+
- image: circleci/openjdk:8-jdk
46+
steps:
47+
- checkout
48+
- add_ssh_keys:
49+
fingerprints:
50+
- "31:63:53:c4:af:b7:2c:a1:62:8e:b0:11:83:f8:62:eb"
51+
- run:
52+
name: Set up git
53+
command: |
54+
git config --global user.name "CircleCI"
55+
git config --global user.email "[email protected]"
56+
ssh-keyscan -T 15 github.com >> ~/.ssh/known_hosts
57+
- setup_remote_docker
58+
- run:
59+
name: Release LTS
60+
command: |
61+
sudo apt-get install -y jq
62+
export VERSION=`jq -r '.lts.version' vars.js`
63+
echo "$DOCKER_PASS" | docker login -u "$DOCKER_USER" --password-stdin
64+
./release-lts.sh
65+
git tag -a $VERSION -m "Release $VERSION."
66+
git push --tags
4367
workflows:
4468
version: 2
4569
pr-build:
@@ -55,9 +79,20 @@ workflows:
5579
filters:
5680
branches:
5781
only: master
82+
- hold-lts:
83+
type: approval
84+
filters:
85+
branches:
86+
only: master
5887
- release:
5988
requires:
6089
- hold
6190
filters:
6291
branches:
6392
only: master
93+
- release-lts:
94+
requires:
95+
- hold-lts
96+
filters:
97+
branches:
98+
only: master

2.11.0-full/Dockerfile

+12
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# SonarQube 6.7.6 LTS image with bundled sonar-scala 6.8.0 (https://github.com/mwz/sonar-scala).
2+
3+
FROM sonarqube:6.7.6-community
4+
5+
ENV SONAR_SCALA_VERSION 6.8.0
6+
7+
WORKDIR /opt/sonarqube/extensions/plugins
8+
RUN wget -O "sonar-scala-plugin-${SONAR_SCALA_VERSION}.jar" \
9+
"https://dl.bintray.com/mwz/maven/com/github/mwz/sonar-scala_2.12/${SONAR_SCALA_VERSION}/sonar-scala_2.12-${SONAR_SCALA_VERSION}-assembly.jar"
10+
11+
WORKDIR $SONARQUBE_HOME
12+
ENTRYPOINT ["./bin/run.sh"]

2.11.0/Dockerfile

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# Minideb image with bundled sonar-scala 6.8.0 (https://github.com/mwz/sonar-scala),
2+
# which can be mounted as a volume into a SonarQube container.
3+
4+
FROM bitnami/minideb:stretch
5+
RUN install_packages curl ca-certificates
6+
7+
ENV SONAR_SCALA_VERSION 6.8.0
8+
9+
RUN groupadd -r sonarqube && useradd -r -g sonarqube sonarqube
10+
WORKDIR /opt/sonarqube/extensions/plugins
11+
RUN curl -L -o "sonar-scala-plugin-${SONAR_SCALA_VERSION}.jar" \
12+
"https://dl.bintray.com/mwz/maven/com/github/mwz/sonar-scala_2.12/${SONAR_SCALA_VERSION}/sonar-scala_2.12-${SONAR_SCALA_VERSION}-assembly.jar"
13+
RUN chown -R sonarqube:sonarqube /opt/sonarqube

README.md

+5-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# sonar-scala-docker
22
[![GitHub version](https://img.shields.io/badge/release-v3.4.0-blue.svg)](https://github.com/mwz/sonarqube-scala-docker/releases)
3-
[![GitHub version lts](https://img.shields.io/badge/release_(LTS)-v2.10.0-blue.svg)](https://github.com/mwz/sonarqube-scala-docker/releases)
3+
[![GitHub version lts](https://img.shields.io/badge/release_(LTS)-v2.11.0-blue.svg)](https://github.com/mwz/sonarqube-scala-docker/releases)
44
[![Docker Pulls](https://img.shields.io/docker/pulls/mwizner/sonarqube-scala-plugins.svg)](https://hub.docker.com/r/mwizner/sonarqube-scala-plugins)
55

66
Docker images and docker-compose recipes for out-of-the-box [SonarQube 6.7 LTS](https://www.sonarqube.org/sonarqube-6-7-lts) and [SonarQube 7.4](https://www.sonarqube.org/sonarqube-7-4) 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:
@@ -19,7 +19,7 @@ docker-compose -f docker-compose-lts.yml up -d
1919

2020
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`.
2121

22-
You can also use a standalone docker image which contains SonarQube server with bundled sonar-scala plugin, [`mwizner/sonarqube-scala-plugins:3.4.0-full`](https://hub.docker.com/r/mwizner/sonarqube-scala-plugins) and [`mwizner/sonarqube-scala-plugins:2.10.0-full`](https://hub.docker.com/r/mwizner/sonarqube-scala-plugins) for the LTS version.
22+
You can also use a standalone docker image which contains SonarQube server with bundled sonar-scala plugin, [`mwizner/sonarqube-scala-plugins:3.4.0-full`](https://hub.docker.com/r/mwizner/sonarqube-scala-plugins) and [`mwizner/sonarqube-scala-plugins:2.11.0-full`](https://hub.docker.com/r/mwizner/sonarqube-scala-plugins) for the LTS version.
2323

2424
To start the container issue the following command:
2525
```bash
@@ -56,7 +56,8 @@ Version | SonarQube | sonar-scala | sonar-scala-extra
5656
[3.2.0](https://github.com/mwz/sonarqube-scala-docker/releases/tag/3.2.0) | 7.4 ([documentation](https://docs.sonarqube.org/7.4))([changelog](https://jira.sonarsource.com/jira/secure/ReleaseNote.jspa?projectId=10930&version=14549)) | [7.2.0](https://github.com/mwz/sonar-scala/releases/tag/v7.2.0)
5757
[3.1.0](https://github.com/mwz/sonarqube-scala-docker/releases/tag/3.1.0) | 7.4 ([documentation](https://docs.sonarqube.org/7.4))([changelog](https://jira.sonarsource.com/jira/secure/ReleaseNote.jspa?projectId=10930&version=14549)) | [7.1.0](https://github.com/mwz/sonar-scala/releases/tag/v7.1.0)
5858
[3.0.0](https://github.com/mwz/sonarqube-scala-docker/releases/tag/3.0.0) | 7.3 ([documentation](https://docs.sonarqube.org/display/SONARQUBE73/Documentation))([changelog](https://jira.sonarsource.com/jira/secure/ReleaseNote.jspa?projectId=10930&version=14464)) | [7.0.0](https://github.com/mwz/sonar-scala/releases/tag/v7.0.0)
59-
[2.10.0](https://github.com/mwz/sonarqube-scala-docker/releases/tag/2.10.0) | 6.7.6 LTS ([documentation](https://docs.sonarqube.org/display/SONARQUBE67/Documentation))([changelog](https://jira.sonarsource.com/jira/secure/ReleaseNote.jspa?projectId=10930&version=13972)) | [6.7.0](https://github.com/mwz/sonar-scala/releases/tag/v6.7.0)
59+
[2.11.0](https://github.com/mwz/sonarqube-scala-docker/releases/tag/2.11.0) | 6.7.6 LTS ([documentation](https://docs.sonarqube.org/display/SONARQUBE67/Documentation))([changelog](https://jira.sonarsource.com/jira/secure/ReleaseNote.jspa?projectId=10930&version=13972)) | [6.8.0](https://github.com/mwz/sonar-scala/releases/tag/v6.8.0)
60+
[2.10.0](https://github.com/mwz/sonarqube-scala-docker/releases/tag/2.10.0) | 6.7.6 LTS ([documentation](https://docs.sonarqube.org/display/SONARQUBE67/Documentation))([changelog](https://jira.sonarsource.com/jira/secure/ReleaseNote.jspa?projectId=10930&version=13972)) | [6.7.0](https://github.com/mwz/sonar-scala/releases/tag/v6.7.0) |
6061
[2.9.0](https://github.com/mwz/sonarqube-scala-docker/releases/tag/2.9.0) | 6.7.5 LTS ([documentation](https://docs.sonarqube.org/display/SONARQUBE67/Documentation))([changelog](https://jira.sonarsource.com/jira/secure/ReleaseNote.jspa?projectId=10930&version=14467)) | [6.6.0](https://github.com/mwz/sonar-scala/releases/tag/v6.6.0) |
6162
[2.8.0](https://github.com/mwz/sonarqube-scala-docker/releases/tag/2.8.0) | 6.7.5 LTS ([documentation](https://docs.sonarqube.org/display/SONARQUBE67/Documentation))([changelog](https://jira.sonarsource.com/jira/secure/ReleaseNote.jspa?projectId=10930&version=14467)) | [6.5.1](https://github.com/mwz/sonar-scala/releases/tag/v6.5.1) |
6263
[2.7.0](https://github.com/mwz/sonarqube-scala-docker/releases/tag/2.7.0) | 6.7.4 LTS ([documentation](https://docs.sonarqube.org/display/SONARQUBE67/Documentation))([changelog](https://jira.sonarsource.com/jira/secure/ReleaseNote.jspa?projectId=10930&version=14377)) | [6.5.0](https://github.com/mwz/sonar-scala/releases/tag/v6.5.0) |
@@ -82,6 +83,7 @@ Please note, that starting from version `2.7.0`, the images no longer contain th
8283
- **3.2.0** - Upgraded sonar-scala to 7.2.0.
8384
- **3.1.0** - Upgraded sonar-scala to 7.1.0 & SonarQube to 7.4.
8485
- **3.0.0** - Upgraded sonar-scala to 7.0.0 & SonarQube to 7.3.
86+
- **2.11.0** - Upgraded sonar-scala to 6.8.0.
8587
- **2.10.0** - Upgraded sonar-scala to 6.7.0 & SonarQube to 6.7.6.
8688
- **2.9.0** - Upgraded sonar-scala to 6.6.0.
8789
- **2.8.0** - Upgraded sonar-scala to 6.5.1 & SonarQube to 6.7.5.

README.tpl.md

+1
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@ Please note, that starting from version `2.7.0`, the images no longer contain th
7373
- **3.2.0** - Upgraded sonar-scala to 7.2.0.
7474
- **3.1.0** - Upgraded sonar-scala to 7.1.0 & SonarQube to 7.4.
7575
- **3.0.0** - Upgraded sonar-scala to 7.0.0 & SonarQube to 7.3.
76+
- **2.11.0** - Upgraded sonar-scala to 6.8.0.
7677
- **2.10.0** - Upgraded sonar-scala to 6.7.0 & SonarQube to 6.7.6.
7778
- **2.9.0** - Upgraded sonar-scala to 6.6.0.
7879
- **2.8.0** - Upgraded sonar-scala to 6.5.1 & SonarQube to 6.7.5.

README_DOCKERHUB.md

+4-1
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,14 @@ Starting from version `2.7.0`, the images no longer contain the [sonar-scala-ext
88

99
#### Current
1010
- `3.4.0` (latest) [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/3.4.0/Dockerfile), `3.4.0-full` [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/3.4.0-full/Dockerfile), [Release 3.4.0](https://github.com/mwz/sonar-scala-docker/releases/tag/3.4.0)
11-
- `2.10.0` (LTS) [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/2.10.0/Dockerfile), `2.10.0-full` (LTS) [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/2.10.0-full/Dockerfile), [Release 2.10.0](https://github.com/mwz/sonar-scala-docker/releases/tag/2.10.0)
11+
- `2.11.0` (LTS) [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/2.11.0/Dockerfile), `2.11.0-full` (LTS) [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/2.11.0-full/Dockerfile), [Release 2.11.0](https://github.com/mwz/sonar-scala-docker/releases/tag/2.11.0)
1212
#### Older
1313
- `3.3.0` [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/3.3.0/Dockerfile), `3.3.0-full` [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/3.3.0-full/Dockerfile), [Release 3.3.0](https://github.com/mwz/sonar-scala-docker/releases/tag/3.3.0)
1414
- `3.2.1` [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/3.2.1/Dockerfile), `3.2.1-full` [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/3.2.1-full/Dockerfile), [Release 3.2.1](https://github.com/mwz/sonar-scala-docker/releases/tag/3.2.1)
1515
- `3.2.0` [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/3.2.0/Dockerfile), `3.2.0-full` [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/3.2.0-full/Dockerfile), [Release 3.2.0](https://github.com/mwz/sonar-scala-docker/releases/tag/3.2.0)
1616
- `3.1.0` [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/3.1.0/Dockerfile), `3.1.0-full` [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/3.1.0-full/Dockerfile), [Release 3.1.0](https://github.com/mwz/sonar-scala-docker/releases/tag/3.1.0)
1717
- `3.0.0` [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/3.0.0/Dockerfile), `3.0.0-full` [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/3.0.0-full/Dockerfile), [Release 3.0.0](https://github.com/mwz/sonar-scala-docker/releases/tag/3.0.0)
18+
- `2.10.0` (LTS) [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/2.10.0/Dockerfile), `2.10.0-full` (LTS) [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/2.10.0-full/Dockerfile), [Release 2.10.0](https://github.com/mwz/sonar-scala-docker/releases/tag/2.10.0)
1819
- `2.9.0` (LTS) [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/2.9.0/Dockerfile), `2.9.0-full` (LTS) [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/2.9.0-full/Dockerfile), [Release 2.9.0](https://github.com/mwz/sonar-scala-docker/releases/tag/2.9.0)
1920
- `2.8.0` (LTS) [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/2.8.0/Dockerfile), `2.8.0-full` (LTS) [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/2.8.0-full/Dockerfile), [Release 2.8.0](https://github.com/mwz/sonar-scala-docker/releases/tag/2.8.0)
2021
- `2.7.0` (LTS) [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/2.7.0/Dockerfile), `2.7.0-full` (LTS) [Dockerfile](https://github.com/mwz/sonar-scala-docker/blob/master/2.7.0-full/Dockerfile), [Release 2.7.0](https://github.com/mwz/sonar-scala-docker/releases/tag/2.7.0)
@@ -42,6 +43,8 @@ Version | SonarQube | sonar-scala | sonar-scala-extra
4243
3.1.0-full | 7.4 | 7.1.0
4344
3.0.0 || 7.0.0
4445
3.0.0-full | 7.3 | 7.0.0
46+
2.11.0 || 6.8.0 |
47+
2.11.0-full | 6.7.6 LTS | 6.8.0 |
4548
2.10.0 || 6.7.0 |
4649
2.10.0-full | 6.7.6 LTS | 6.7.0 |
4750
2.9.0 || 6.6.0 |

docker-compose-lts.yml

+20-20
Original file line numberDiff line numberDiff line change
@@ -1,48 +1,48 @@
11
version: "2"
22

33
services:
4-
sonarqube:
4+
sonarqube-lts:
55
image: sonarqube:6.7.6-community # lts
66
ports:
77
- "80:9000"
88
networks:
9-
- sonarnet
9+
- sonarnet_lts
1010
environment:
1111
- SONARQUBE_JDBC_USERNAME=sonar
1212
- SONARQUBE_JDBC_PASSWORD=sonar
13-
- SONARQUBE_JDBC_URL=jdbc:postgresql://db:5432/sonar
13+
- SONARQUBE_JDBC_URL=jdbc:postgresql://db-lts:5432/sonar
1414
volumes:
1515
- ./conf/sonar-lts.properties:/opt/sonarqube/conf/sonar.properties
1616
- ./logs:/opt/sonarqube/logs
17-
- sonarqube_data:/opt/sonarqube/data
18-
- sonarqube_bundled-plugins:/opt/sonarqube/lib/bundled-plugins
17+
- sonarqube_lts_data:/opt/sonarqube/data
18+
- sonarqube_lts_bundled-plugins:/opt/sonarqube/lib/bundled-plugins
1919
volumes_from:
20-
- plugins
20+
- plugins-lts
2121
depends_on:
22-
- db
23-
db:
22+
- db-lts
23+
db-lts:
2424
image: postgres:10.6-alpine
2525
networks:
26-
- sonarnet
26+
- sonarnet_lts
2727
environment:
2828
- POSTGRES_USER=sonar
2929
- POSTGRES_PASSWORD=sonar
3030
volumes:
31-
- postgresql:/var/lib/postgresql
32-
- postgresql_data:/var/lib/postgresql/data
33-
plugins:
34-
image: mwizner/sonarqube-scala-plugins:2.10.0
31+
- postgresql_lts:/var/lib/postgresql
32+
- postgresql_lts_data:/var/lib/postgresql/data
33+
plugins-lts:
34+
image: mwizner/sonarqube-scala-plugins:2.11.0
3535
volumes:
36-
- sonarqube_plugins:/opt/sonarqube/extensions/plugins
36+
- sonarqube_lts_plugins:/opt/sonarqube/extensions/plugins
3737
command: /bin/true
3838

3939
networks:
40-
sonarnet:
40+
sonarnet_lts:
4141
driver: bridge
4242

4343
volumes:
44-
sonarqube_data:
45-
sonarqube_bundled-plugins:
46-
sonarqube_plugins:
47-
postgresql:
48-
postgresql_data:
44+
sonarqube_lts_data:
45+
sonarqube_lts_bundled-plugins:
46+
sonarqube_lts_plugins:
47+
postgresql_lts:
48+
postgresql_lts_data:

release-lts.sh

-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
#!/usr/bin/env bash
22
set -eu
33

4-
export VERSION=2.10.0
5-
64
# Build
75
docker build -t mwizner/sonarqube-scala-plugins:$VERSION $VERSION
86
docker build -t mwizner/sonarqube-scala-plugins:$VERSION-full $VERSION-full

vars.js

+9-2
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,11 @@
77
"sonarScala": "7.3.1"
88
},
99
"lts": {
10-
"version": "2.10.0",
10+
"version": "2.11.0",
1111
"sonar": "6.7.6 LTS",
1212
"sonarDocs": "https://docs.sonarqube.org/display/SONARQUBE67/Documentation",
1313
"sonarChangelog": "https://jira.sonarsource.com/jira/secure/ReleaseNote.jspa?projectId=10930&version=13972",
14-
"sonarScala": "6.7.0"
14+
"sonarScala": "6.8.0"
1515
},
1616
"versions": {
1717
"current": [
@@ -52,6 +52,13 @@
5252
}
5353
],
5454
"lts": [
55+
{
56+
"version": "2.10.0",
57+
"sonar": "6.7.6 LTS",
58+
"sonarDocs": "https://docs.sonarqube.org/display/SONARQUBE67/Documentation",
59+
"sonarChangelog": "https://jira.sonarsource.com/jira/secure/ReleaseNote.jspa?projectId=10930&version=13972",
60+
"sonarScala": "6.7.0"
61+
},
5562
{
5663
"version": "2.9.0",
5764
"sonar": "6.7.5 LTS",

0 commit comments

Comments
 (0)