From fb2e9cf8597980d49d7b6153518e94b4000cd6a9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9da=20Housni=20Alaoui?= Date: Fri, 13 Sep 2024 17:50:11 +0200 Subject: [PATCH] Fix the build --- .github/release-drafter.yml | 1 + .github/workflows/cd.yaml | 15 --------------- .github/workflows/jenkins-security-scan.yml | 8 +++++--- .github/workflows/release-drafter.yml | 17 +++++++++++++++++ Jenkinsfile | 9 ++++++++- pom.xml | 11 +++++------ .../LogbackConfigurator.java | 4 +++- .../sonarqube/SonarqubeServer.java | 2 +- 8 files changed, 40 insertions(+), 27 deletions(-) delete mode 100644 .github/workflows/cd.yaml create mode 100644 .github/workflows/release-drafter.yml diff --git a/.github/release-drafter.yml b/.github/release-drafter.yml index 0d0b1c99..d98cff48 100644 --- a/.github/release-drafter.yml +++ b/.github/release-drafter.yml @@ -1 +1,2 @@ _extends: .github +tag-template: demo-$NEXT_MINOR_VERSION diff --git a/.github/workflows/cd.yaml b/.github/workflows/cd.yaml deleted file mode 100644 index 0279984d..00000000 --- a/.github/workflows/cd.yaml +++ /dev/null @@ -1,15 +0,0 @@ -# Note: additional setup is required, see https://www.jenkins.io/redirect/continuous-delivery-of-plugins - -name: cd -on: - workflow_dispatch: - check_run: - types: - - completed - -jobs: - maven-cd: - uses: jenkins-infra/github-reusable-workflows/.github/workflows/maven-cd.yml@v1 - secrets: - MAVEN_USERNAME: ${{ secrets.MAVEN_USERNAME }} - MAVEN_TOKEN: ${{ secrets.MAVEN_TOKEN }} diff --git a/.github/workflows/jenkins-security-scan.yml b/.github/workflows/jenkins-security-scan.yml index c7b41fc2..f1995d84 100644 --- a/.github/workflows/jenkins-security-scan.yml +++ b/.github/workflows/jenkins-security-scan.yml @@ -1,9 +1,11 @@ -name: Jenkins Security Scan +# More information about the Jenkins security scan can be found at the developer docs: https://www.jenkins.io/redirect/jenkins-security-scan/ +name: Jenkins Security Scan on: push: branches: - - master + - "master" + - "main" pull_request: types: [ opened, synchronize, reopened ] workflow_dispatch: @@ -18,4 +20,4 @@ jobs: uses: jenkins-infra/jenkins-security-scan/.github/workflows/jenkins-security-scan.yaml@v2 with: java-cache: 'maven' # Optionally enable use of a build dependency cache. Specify 'maven' or 'gradle' as appropriate. - # java-version: 21 # Optionally specify what version of Java to set up for the build, or remove to use a recent default. + java-version: 11 # What version of Java to set up for the build. diff --git a/.github/workflows/release-drafter.yml b/.github/workflows/release-drafter.yml new file mode 100644 index 00000000..58835450 --- /dev/null +++ b/.github/workflows/release-drafter.yml @@ -0,0 +1,17 @@ +# Automates creation of Release Drafts using Release Drafter +# More Info: https://github.com/jenkinsci/.github/blob/master/.github/release-drafter.adoc + +on: + push: + branches: + - master + - main + +jobs: + update_release_draft: + runs-on: ubuntu-latest + steps: + # Drafts your next Release notes as Pull Requests are merged into the default branch + - uses: release-drafter/release-drafter@v5 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/Jenkinsfile b/Jenkinsfile index 48bf230e..9a2628d0 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1 +1,8 @@ -buildPlugin() \ No newline at end of file +buildPlugin( + useContainerAgent: false, // Set to `false` if you need to use Docker for containerized tests + timeout: 180, + configurations: [ + [platform: 'linux', jdk: 21], + [platform: 'windows', jdk: 17], + ] +) \ No newline at end of file diff --git a/pom.xml b/pom.xml index 419dc602..289a7604 100644 --- a/pom.xml +++ b/pom.xml @@ -6,7 +6,7 @@ org.jenkins-ci.plugins plugin - 4.32 + 4.87 @@ -18,9 +18,8 @@ 999999-SNAPSHOT jenkinsci/${project.artifactId}-plugin - 2.277.4 - 8 - 1674.v3b8b1441e939 + 2.361.4 + 2225.2230.v6210cb_b_827f9