diff --git a/.default.docker.env b/.default.docker.env index 8a64376..aed2dd9 100644 --- a/.default.docker.env +++ b/.default.docker.env @@ -1,5 +1,5 @@ -MAVEN_BUILDER_VERSION=3-openjdk-11-slim -SONARQUBE_VERSION=10.5.1-community +MAVEN_BUILDER_VERSION=3-openjdk-17-slim +SONARQUBE_VERSION=10.6.0-community POSTGRES_VERSION=12 DOCKER_BUILDKIT=1 COMPOSE_DOCKER_CLI_BUILD=1 diff --git a/CHANGELOG.md b/CHANGELOG.md index a9c792d..1ce62a8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,23 +13,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Deleted -## [1.7.0] - 2024-07-13 - -### Added - -- Add **toolbox.sh** utility script for SonarQube development environment installation -- Add **utils.sh** Add utils.sh script to launch toolbox commands -- Addition of the pytest framework for unit testing bash scripts -- - -### Changed - -- Update of the "Getting Started" section in the README file - -### Deleted - -- Removal of utility scripts already present in the toolbox.sh script - ## [1.6.1] - 2024-05-15 ### Changed diff --git a/Dockerfile b/Dockerfile index 7d1b676..f907cf2 100644 --- a/Dockerfile +++ b/Dockerfile @@ -14,3 +14,4 @@ RUN ${ECOCODE_SRC_PATH}/toolbox.sh build FROM sonarqube:${SONARQUBE_VERSION} COPY --from=builder ${ECOCODE_SRC_PATH}/target/ecocode-*.jar ${SONARQUBE_PLUGINS_PATH} +USER sonarqube diff --git a/docker-compose.yml b/docker-compose.yml index 03e29ab..ca32556 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -10,11 +10,12 @@ services: - SONARQUBE_VERSION=${SONARQUBE_VERSION} container_name: sonar_ecocode_java ports: - - "9000:9000" + - ":9000" networks: - sonarnet depends_on: - - db + db: + condition: service_healthy environment: SONAR_JDBC_USERNAME: sonar SONAR_JDBC_PASSWORD: sonar @@ -37,6 +38,12 @@ services: POSTGRES_PASSWORD: sonar POSTGRES_DB: sonarqube PGDATA: pg_data:/var/lib/postgresql/data/pgdata + healthcheck: + test: [ "CMD-SHELL", "pg_isready -U sonar -d sonarqube" ] + interval: 5s + timeout: 5s + retries: 5 + networks: sonarnet: