From 06f8535386a616fb0247fc44617d761420e91e3f Mon Sep 17 00:00:00 2001 From: Avgustin Marinov Date: Wed, 2 Aug 2023 11:51:56 +0300 Subject: [PATCH] Fixed some CI flows & checks (#1405) Signed-off-by: Marinov Avgustin --- .azure-pipelines/integration-tests.yml | 21 ++++++++++++++------- .azure-pipelines/maven-template.yml | 2 +- .circleci/config.yml | 2 +- .github/workflows/trivy-scan.yml | 6 +++--- 4 files changed, 19 insertions(+), 12 deletions(-) diff --git a/.azure-pipelines/integration-tests.yml b/.azure-pipelines/integration-tests.yml index 9c812bc4e..1fb34ee0c 100644 --- a/.azure-pipelines/integration-tests.yml +++ b/.azure-pipelines/integration-tests.yml @@ -26,25 +26,32 @@ variables: - group: hawkbit jobs: - - job: JDK_11 - displayName: Verify with JDK-11 and SonarCloud analysis + - job: JDK + displayName: Verify with hawkBit default JDK and SonarCloud analysis steps: - template: rabbitmq-template.yml - template: maven-template.yml parameters: mavenGoals: "verify -Dsonar.host.url=https://sonarcloud.io -Dsonar.organization=$(sonarCloudOrganization) -Dsonar.projectKey=$(sonarProjectKey)" - jdkVersionOption: "1.11" sonarQubeRunAnalysis: true sonarCloudConnection: $(sonarCloudConnection) sonarCloudOrganization: $(sonarCloudOrganization) + - job: JDK_11 + displayName: Build with JDK-11 (hawkBit default) + steps: + - template: maven-template.yml + parameters: + mavenGoals: "install license:check" + jdkVersionOption: "1.11" - job: JDK_8 displayName: Build with JDK-8 (hawkBit default) steps: - template: maven-template.yml parameters: mavenGoals: "install license:check" + jdkVersionOption: "1.8" - job: - dependsOn: JDK_8 + dependsOn: JDK condition: succeeded() displayName: RABBIT strategy: @@ -63,7 +70,7 @@ jobs: parameters: mavenGoals: "verify" - job: - dependsOn: JDK_8 + dependsOn: JDK condition: succeeded() displayName: MYSQL strategy: @@ -80,7 +87,7 @@ jobs: parameters: mavenGoals: "verify -Dspring.jpa.database=MYSQL -Dspring.datasource.driverClassName=org.mariadb.jdbc.Driver -Dspring.datasource.url=jdbc:mariadb://localhost:3306/hawkbit -Dspring.datasource.username=root -Dspring.datasource.password=8236472364" - job: - dependsOn: JDK_8 + dependsOn: JDK condition: succeeded() displayName: MSSQL strategy: @@ -101,7 +108,7 @@ jobs: parameters: mavenGoals: "verify -Dspring.jpa.database=SQL_SERVER -Dspring.datasource.url=jdbc:sqlserver://localhost:1433;database=hawkbit -Dspring.datasource.username=SA -Dspring.datasource.password=1234567890.Ab -Dspring.datasource.driverClassName=com.microsoft.sqlserver.jdbc.SQLServerDriver" - job: - dependsOn: JDK_8 + dependsOn: JDK condition: succeeded() displayName: POSTGRESQL strategy: diff --git a/.azure-pipelines/maven-template.yml b/.azure-pipelines/maven-template.yml index 5f8ba8445..3e5239ad9 100644 --- a/.azure-pipelines/maven-template.yml +++ b/.azure-pipelines/maven-template.yml @@ -5,7 +5,7 @@ parameters: - name: jdkVersionOption displayName: JDK Version type: string - default: "1.8" + default: "1.17" - name: sonarQubeRunAnalysis displayName: Enable SonarQube analysis type: boolean diff --git a/.circleci/config.yml b/.circleci/config.yml index e667adcc3..a93c9a21d 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -14,7 +14,7 @@ jobs: working_directory: ~/hawkBit docker: - - image: cimg/openjdk:17.0.7 + - image: cimg/openjdk:17.0.8 auth: username: $DOCKERHUB_USER password: $DOCKERHUB_ACCESSTOKEN diff --git a/.github/workflows/trivy-scan.yml b/.github/workflows/trivy-scan.yml index cc64001a8..333dbfb81 100644 --- a/.github/workflows/trivy-scan.yml +++ b/.github/workflows/trivy-scan.yml @@ -23,11 +23,11 @@ jobs: - name: Set up JDK uses: actions/setup-java@v3 with: - distribution: "adopt" - java-version: "11" + distribution: "temurin" + java-version: "17" cache: "maven" - - name: Create Hawkbit container images + - name: Create hawkBit container images run: | mvn clean install -DskipTests -Pdocker