Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

52 update to sonarqube 10 #54

Merged
merged 3 commits into from
Sep 5, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
- run:
shell: /bin/bash
command: |
docker build -f Dockerfile-community-edition -t ictu/sonar:${CIRCLE_TAG} .
docker build -t ictu/sonar:${CIRCLE_TAG} .
docker login -u $DOCKER_USER -p $DOCKER_PASS
docker push ictu/sonar:${CIRCLE_TAG}
build_and_push_de_tag:
Expand All @@ -18,7 +18,7 @@ jobs:
- run:
shell: /bin/bash
command: |
docker build -f Dockerfile-developer-edition -t ictu/sonar:${CIRCLE_TAG} .
docker build --build-arg="IMAGE_EDITION=developer" -t ictu/sonar:${CIRCLE_TAG} .
docker login -u $DOCKER_USER -p $DOCKER_PASS
docker push ictu/sonar:${CIRCLE_TAG}

Expand Down
35 changes: 35 additions & 0 deletions .github/workflows/docker-image.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Docker Image CI

on:
push:
branches:
- master
pull_request:
types: [opened, synchronize, reopened]

jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
include:
- env:
IMAGE_EDITION: community
- env:
IMAGE_EDITION: developer
steps:
- uses: actions/checkout@v3

- name: Build the Docker image
run: docker build --build-arg="IMAGE_EDITION=${{ matrix.env.IMAGE_EDITION }}" -t ci .

- name: Run the Docker image
run: docker run -d --name ci ci

- name: Verify the Docker image
# profile for language 'web' is the last; assume everything is working if we got this far
run: docker logs -f ci |& sed '/Current profile for language web is Sonar way/ q'
timeout-minutes: 3

- name: Stop the Docker image
run: docker stop ci
5 changes: 4 additions & 1 deletion Dockerfile-community-edition → Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
FROM sonarqube:9.9.1-community
ARG IMAGE_NAME=sonarqube
ARG IMAGE_VERSION=10.1.0
ARG IMAGE_EDITION=community
FROM $IMAGE_NAME:$IMAGE_VERSION-$IMAGE_EDITION
USER root
RUN apt-get update && apt-get install -y wget curl ca-certificates-java jq postgresql-client \
&& rm -rf /var/lib/apt/lists/*
Expand Down
17 changes: 0 additions & 17 deletions Dockerfile-developer-edition

This file was deleted.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ Example docker-compose file:
version: '3.7'
services:
www:
image: ictu/sonar:9.9.1
image: ictu/sonar:10.1.0
environment:
- SONAR_JDBC_URL=jdbc:postgresql://db:5432/sonar
- SONAR_JDBC_USERNAME=sonar
Expand Down
6 changes: 3 additions & 3 deletions plugins/plugin-list
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
https://github.com/checkstyle/sonar-checkstyle/releases/download/10.9.3/checkstyle-sonar-plugin-10.9.3.jar
https://github.com/sbaudoin/sonar-ansible/releases/download/v2.5.1/sonar-ansible-plugin-2.5.1.jar
https://github.com/dependency-check/dependency-check-sonar-plugin/releases/download/3.1.0/sonar-dependency-check-plugin-3.1.0.jar
https://github.com/checkstyle/sonar-checkstyle/releases/download/10.12.3/checkstyle-sonar-plugin-10.12.3.jar
https://github.com/dependency-check/dependency-check-sonar-plugin/releases/download/4.0.0/sonar-dependency-check-plugin-4.0.0.jar
https://github.com/jborgers/sonar-pmd/releases/download/3.4.0/sonar-pmd-plugin-3.4.0.jar
https://github.com/sbaudoin/sonar-yaml/releases/download/v1.7.0/sonar-yaml-plugin-1.7.0.jar
https://github.com/spotbugs/sonar-findbugs/releases/download/4.2.3/sonar-findbugs-plugin-4.2.3.jar
https://github.com/vaulttec/sonar-auth-oidc/releases/download/v2.1.1/sonar-auth-oidc-plugin-2.1.1.jar
https://github.com/sbaudoin/sonar-ansible/releases/download/v2.5.1/sonar-ansible-plugin-2.5.1.jar
18 changes: 9 additions & 9 deletions start-with-profile.sh
Original file line number Diff line number Diff line change
Expand Up @@ -268,14 +268,14 @@ testAdminCredentials

# (Re-)create the ICTU profiles
RULES_VERSION=20230619
createProfile "ictu-ansible-profile-v2.5.1-${RULES_VERSION}" "Sonar%20way" "yaml"
createProfile "ictu-cs-profile-v8.51.0-${RULES_VERSION}" "Sonar%20way" "cs"
createProfile "ictu-java-profile-v7.16.0-${RULES_VERSION}" "Sonar%20way" "java"
createProfile "ictu-js-profile-v9.13.0-${RULES_VERSION}" "Sonar%20way" "js"
createProfile "ictu-kotlin-profile-v2.12.0-${RULES_VERSION}" "Sonar%20way" "kotlin"
createProfile "ictu-py-profile-v3.24.0-${RULES_VERSION}" "Sonar%20way" "py"
createProfile "ictu-ts-profile-v9.13.0-${RULES_VERSION}" "Sonar%20way" "ts"
createProfile "ictu-vbnet-profile-v8.51.0-${RULES_VERSION}" "Sonar%20way" "vbnet"
createProfile "ictu-web-profile-v3.7.1-${RULES_VERSION}" "Sonar%20way" "web"
createProfile "ictu-ansible-profile-v2.5.1-${RULES_VERSION}" "Sonar%20way" "yaml" # custom sonar-ansible-plugin
createProfile "ictu-cs-profile-v9.3.0-${RULES_VERSION}" "Sonar%20way" "cs" # image csharp-plugin
createProfile "ictu-java-profile-v7.20.0-${RULES_VERSION}" "Sonar%20way" "java" # image java-plugin
createProfile "ictu-js-profile-v10.3.1-${RULES_VERSION}" "Sonar%20way" "js" # image javascript-plugin
createProfile "ictu-kotlin-profile-v2.15.0-${RULES_VERSION}" "Sonar%20way" "kotlin" # image kotlin-plugin
createProfile "ictu-py-profile-v4.3.0-${RULES_VERSION}" "Sonar%20way" "py" # image python-plugin
createProfile "ictu-ts-profile-v10.3.1-${RULES_VERSION}" "Sonar%20way" "ts" # image javascript-plugin
createProfile "ictu-vbnet-profile-v9.3.0-${RULES_VERSION}" "Sonar%20way" "vbnet" # image vbnet-plugin
createProfile "ictu-web-profile-v3.8.0-${RULES_VERSION}" "Sonar%20way" "web" # image html-plugin

wait $PID