You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kie.apache.org by js...@apache.org on 2023/09/19 16:13:12 UTC

[incubator-kie-optaplanner-quickstarts] branch apache_migration_stable created (now 515d8a5a)

This is an automated email from the ASF dual-hosted git repository.

jstastnycz pushed a change to branch apache_migration_stable
in repository https://gitbox.apache.org/repos/asf/incubator-kie-optaplanner-quickstarts.git


      at 515d8a5a mostly GHA change from kie-ci to kogito-pipelines

This branch includes the following new commits:

     new 515d8a5a mostly GHA change from kie-ci to kogito-pipelines

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org
For additional commands, e-mail: commits-help@kie.apache.org


[incubator-kie-optaplanner-quickstarts] 01/01: mostly GHA change from kie-ci to kogito-pipelines

Posted by js...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

jstastnycz pushed a commit to branch apache_migration_stable
in repository https://gitbox.apache.org/repos/asf/incubator-kie-optaplanner-quickstarts.git

commit 515d8a5a24ac00186988b17f00b10d09fe63a2c7
Author: radtriste <tr...@redhat.com>
AuthorDate: Tue Sep 5 11:11:55 2023 +0200

    mostly GHA change from kie-ci to kogito-pipelines
---
 .ci/environments/common/update_quarkus.sh          |  2 +-
 .ci/jenkins/Jenkinsfile                            | 43 ++++++++++++++++
 .ci/jenkins/Jenkinsfile.setup-branch               | 21 ++------
 .ci/jenkins/dsl/jobs.groovy                        |  9 ++--
 .ci/jenkins/dsl/test.sh                            |  8 +--
 .github/pull_request_template.md                   |  6 +--
 .github/workflows/full-downstream.yml              |  4 +-
 .github/workflows/jenkins-tests-PR.yml             |  6 +--
 .github/workflows/nightly.yml                      |  6 +--
 .github/workflows/pr-backporting.yml               |  4 +-
 .github/workflows/pull_request.yml                 | 10 ++--
 .github/workflows/quarkus-snapshot.yml             |  2 +-
 .../workflows/rhbop_productized_pull_request.yml   | 57 ----------------------
 13 files changed, 76 insertions(+), 102 deletions(-)

diff --git a/.ci/environments/common/update_quarkus.sh b/.ci/environments/common/update_quarkus.sh
index 6ac5e81e..2c2e7064 100755
--- a/.ci/environments/common/update_quarkus.sh
+++ b/.ci/environments/common/update_quarkus.sh
@@ -3,7 +3,7 @@ set -euo pipefail
 
 mvn_cmd="mvn ${BUILD_MVN_OPTS:-} ${BUILD_MVN_OPTS_QUARKUS_UPDATE:-}"
 
-source <(curl -s https://raw.githubusercontent.com/kiegroup/kogito-pipelines/main/dsl/seed/scripts/install_quarkus.sh)
+source <(curl -s https://raw.githubusercontent.com/apache/incubator-kie-kogito-pipelines/main/dsl/seed/scripts/install_quarkus.sh)
 
 echo "Update project with Quarkus version ${QUARKUS_VERSION}"
 
diff --git a/.ci/jenkins/Jenkinsfile b/.ci/jenkins/Jenkinsfile
new file mode 100644
index 00000000..61d72e4f
--- /dev/null
+++ b/.ci/jenkins/Jenkinsfile
@@ -0,0 +1,43 @@
+@Library('jenkins-pipeline-shared-libraries')_
+
+pr_check_script = null
+
+pipeline {
+    agent {
+        label 'ubuntu'
+    }
+    options {
+        timestamps()
+        timeout(time: 360, unit: 'MINUTES')
+    }
+    environment {
+        BUILDCHAIN_PROJECT = 'apache/incubator-kie-optaplanner-quickstarts'
+        BUILDCHAIN_CONFIG_REPO = 'incubator-kie-optaplanner'
+        BUILDCHAIN_CONFIG_FILE_PATH = '.ci/buildchain-config.yaml'
+
+        OPTAPLANNER_BUILD_MVN_OPTS_UPSTREAM = '-Dfull'
+        BUILD_MVN_OPTS_CURRENT = '-Dfull'
+    }
+    stages {
+        stage('Initialize') {
+            steps {
+                script {
+                    // load `pr_check.groovy` file from kogito-pipelines:main
+                    dir('kogito-pipelines') {
+                        checkout(githubscm.resolveRepository('incubator-kie-kogito-pipelines', 'apache', 'main', false, 'ASF_Cloudbees_Jenkins_ci-builds'))
+                        pr_check_script = load 'dsl/scripts/pr_check.groovy'
+                    }
+                }
+            }
+        }
+        stage('PR check') {
+            steps {
+                script {
+                    dir('kogito-pipelines') {
+                        pr_check_script.launch()
+                    }
+                }
+            }
+        }
+    }
+}
diff --git a/.ci/jenkins/Jenkinsfile.setup-branch b/.ci/jenkins/Jenkinsfile.setup-branch
index fd3596ab..d7320ce4 100644
--- a/.ci/jenkins/Jenkinsfile.setup-branch
+++ b/.ci/jenkins/Jenkinsfile.setup-branch
@@ -3,16 +3,14 @@ import org.jenkinsci.plugins.workflow.libs.Library
 
 import org.kie.jenkins.MavenCommand
 
-optaplannerRepo = 'optaplanner'
+optaplannerRepo = 'incubator-kie-optaplanner'
 
 pipeline {
     agent {
-        label 'kie-rhel8 && !built-in'
-    }
-
-    tools {
-        maven env.BUILD_MAVEN_TOOL
-        jdk env.BUILD_JDK_TOOL
+        docker { 
+            image env.AGENT_DOCKER_BUILDER_IMAGE
+            args env.AGENT_DOCKER_BUILDER_ARGS
+        }
     }
 
     options {
@@ -20,17 +18,8 @@ pipeline {
         timeout(time: 60, unit: 'MINUTES')
     }
 
-    // parameters {
-    // For parameters, check into ./dsl/jobs.groovy file
-    // }
-
     environment {
-        // Static env is defined into ./dsl/jobs.groovy file
-
         OPTAPLANNER_CI_EMAIL_TO = credentials("${JENKINS_EMAIL_CREDS_ID}")
-
-        // Keep here for visitibility
-        MAVEN_OPTS = '-Xms1024m -Xmx4g'
     }
 
     stages {
diff --git a/.ci/jenkins/dsl/jobs.groovy b/.ci/jenkins/dsl/jobs.groovy
index 314898c4..48d902e2 100644
--- a/.ci/jenkins/dsl/jobs.groovy
+++ b/.ci/jenkins/dsl/jobs.groovy
@@ -2,10 +2,10 @@
 * This file is describing all the Jenkins jobs in the DSL format (see https://plugins.jenkins.io/job-dsl/)
 * needed by the Kogito pipelines.
 *
-* The main part of Jenkins job generation is defined into the https://github.com/kiegroup/kogito-pipelines repository.
+* The main part of Jenkins job generation is defined into the https://github.com/apache/incubator-kie-kogito-pipelines repository.
 *
 * This file is making use of shared libraries defined in
-* https://github.com/kiegroup/kogito-pipelines/tree/main/dsl/seed/src/main/groovy/org/kie/jenkins/jobdsl.
+* https://github.com/apache/incubator-kie-kogito-pipelines/tree/main/dsl/seed/src/main/groovy/org/kie/jenkins/jobdsl.
 */
 
 import org.kie.jenkins.jobdsl.model.JobType
@@ -35,7 +35,7 @@ Map getMultijobPRConfig() {
 }
 
 // Optaplanner PR checks
-KogitoJobUtils.createAllEnvironmentsPerRepoPRJobs(this) { jobFolder -> getMultijobPRConfig() }
+Utils.isMainBranch(this) && KogitoJobTemplate.createPullRequestMultibranchPipelineJob(this, "${jenkins_path}/Jenkinsfile")
 
 // Init branch
 createSetupBranchJob()
@@ -62,9 +62,8 @@ void setupSpecificBuildChainNightlyJob(String envName) {
 
 void createSetupBranchJob() {
     def jobParams = JobParamsUtils.getBasicJobParams(this, 'optaplanner-quickstarts', JobType.SETUP_BRANCH, "${jenkins_path}/Jenkinsfile.setup-branch", 'OptaPlanner Quickstarts Setup Branch')
-    JobParamsUtils.setupJobParamsDefaultMavenConfiguration(this, jobParams)
+    JobParamsUtils.setupJobParamsAgentDockerBuilderImageConfiguration(this, jobParams)
     jobParams.env.putAll([
-        REPO_NAME: 'optaplanner-quickstarts',
         JENKINS_EMAIL_CREDS_ID: "${JENKINS_EMAIL_CREDS_ID}",
 
         GIT_AUTHOR: "${GIT_AUTHOR_NAME}",
diff --git a/.ci/jenkins/dsl/test.sh b/.ci/jenkins/dsl/test.sh
index 1dd3b10f..5449b263 100755
--- a/.ci/jenkins/dsl/test.sh
+++ b/.ci/jenkins/dsl/test.sh
@@ -22,13 +22,13 @@ fi
 
 git_author="$(echo ${git_url} | awk -F"${git_server_url}" '{print $2}' | awk -F. '{print $1}'  | awk -F/ '{print $1}')"
 
-export DSL_DEFAULT_MAIN_CONFIG_FILE_REPO="${git_author}"/optaplanner
-export DSL_DEFAULT_FALLBACK_MAIN_CONFIG_FILE_REPO=kiegroup/optaplanner
+export DSL_DEFAULT_MAIN_CONFIG_FILE_REPO="${git_author}"/incubator-kie-optaplanner
+export DSL_DEFAULT_FALLBACK_MAIN_CONFIG_FILE_REPO=apache/incubator-kie-optaplanner
 export DSL_DEFAULT_MAIN_CONFIG_FILE_PATH=.ci/jenkins/config/main.yaml
-export DSL_DEFAULT_BRANCH_CONFIG_FILE_REPO="${git_author}"/optaplanner
+export DSL_DEFAULT_BRANCH_CONFIG_FILE_REPO="${git_author}"/incubator-kie-optaplanner
 
 file=$(mktemp)
 # For more usage of the script, use ./test.sh -h
-curl -o ${file} https://raw.githubusercontent.com/kiegroup/kogito-pipelines/main/dsl/seed/scripts/seed_test.sh
+curl -o ${file} https://raw.githubusercontent.com/apache/incubator-kie-kogito-pipelines/main/dsl/seed/scripts/seed_test.sh
 chmod u+x ${file}
 ${file} $@
\ No newline at end of file
diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md
index b4097a1c..1a728734 100644
--- a/.github/pull_request_template.md
+++ b/.github/pull_request_template.md
@@ -19,11 +19,11 @@ and also the external https://github.com/quarkusio/quarkus-quickstarts/tree/main
 ### Referenced pull requests
 
 <!-- Add URLs of all referenced pull requests if they exist. This is only required when making
-changes that span multiple kiegroup repositories and depend on each other. -->
+changes that span multiple KIE repositories and depend on each other. -->
 <!-- Example:
 - https://github.com/kiegroup/droolsjbpm-build-bootstrap/pull/1234
-- https://github.com/kiegroup/drools/pull/3000
-- https://github.com/kiegroup/optaplanner/pull/899
+- https://github.com/apache/incubator-kie-drools/pull/3000
+- https://github.com/apache/incubator-kie-optaplanner/pull/899
 - etc.
 -->
 
diff --git a/.github/workflows/full-downstream.yml b/.github/workflows/full-downstream.yml
index dffec7ce..61df5054 100644
--- a/.github/workflows/full-downstream.yml
+++ b/.github/workflows/full-downstream.yml
@@ -52,9 +52,9 @@ jobs:
           restore-keys: ${{ runner.os }}-${{ matrix.java-version }}-m2
       - name: Build Chain ${{ matrix.java-version }}
         id: build-chain
-        uses: kiegroup/github-action-build-chain@v3.1.10
+        uses: apache/incubator-kie-kogito-pipelines/.ci/actions/build-chain@v3.1.10
         with:
-          definition-file: https://raw.githubusercontent.com/${GROUP}/optaplanner/main/.ci/buildchain-config.yaml
+          definition-file: https://raw.githubusercontent.com/${GROUP}/incubator-kie-optaplanner/main/.ci/buildchain-config.yaml
         env:
           GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
           OPTAPLANNER_BUILD_MVN_OPTS_UPSTREAM: "-Dfull"
diff --git a/.github/workflows/jenkins-tests-PR.yml b/.github/workflows/jenkins-tests-PR.yml
index bfb08b1b..5e11cb91 100644
--- a/.github/workflows/jenkins-tests-PR.yml
+++ b/.github/workflows/jenkins-tests-PR.yml
@@ -22,10 +22,10 @@ jobs:
         fi
         echo "BASE_BRANCH=${branch}"  >> $GITHUB_ENV
     - name: DSL tests
-      uses: kiegroup/kie-ci/.ci/actions/dsl-tests@main
+      uses: apache/incubator-kie-kogito-pipelines/.ci/actions/dsl-tests@main
       with:
         project: optaplanner
-        main-config-file-repo: kiegroup/optaplanner
+        main-config-file-repo: apache/incubator-kie-optaplanner
         main-config-file-path: .ci/jenkins/config/main.yaml
-        branch-config-file-repo: kiegroup/optaplanner
+        branch-config-file-repo: apache/incubator-kie-optaplanner
         base-branch: ${{ env.BASE_BRANCH }}
\ No newline at end of file
diff --git a/.github/workflows/nightly.yml b/.github/workflows/nightly.yml
index b79e74eb..aa65e1b7 100644
--- a/.github/workflows/nightly.yml
+++ b/.github/workflows/nightly.yml
@@ -8,7 +8,7 @@ on:
 
 jobs:
   nightly:
-    if: github.repository == 'kiegroup/optaplanner-quickstarts'
+    if: github.repository == 'apache/incubator-kie-optaplanner-quickstarts'
     concurrency:
       group: nightly
       cancel-in-progress: true
@@ -22,9 +22,9 @@ jobs:
     steps:
       - name: Support long paths
         if: ${{ matrix.os == 'windows-latest' }}
-        uses: kiegroup/kie-ci/.ci/actions/long-paths@main
+        uses: apache/incubator-kie-kogito-pipelines/.ci/actions/long-paths@main
       - name: Java and Maven Setup
-        uses: kiegroup/kie-ci/.ci/actions/maven@main
+        uses: apache/incubator-kie-kogito-pipelines/.ci/actions/maven@main
         with:
           java-version: ${{ matrix.java-version }}
           maven-version: ${{ matrix.maven-version }}
diff --git a/.github/workflows/pr-backporting.yml b/.github/workflows/pr-backporting.yml
index 62b31d56..5a763c70 100644
--- a/.github/workflows/pr-backporting.yml
+++ b/.github/workflows/pr-backporting.yml
@@ -17,7 +17,7 @@ jobs:
     steps:
       - name: Set target branches
         id: set-targets
-        uses: kiegroup/kie-ci/.ci/actions/parse-labels@main
+        uses: apache/incubator-kie-kogito-pipelines/.ci/actions/parse-labels@main
         with:
           labels: ${LABELS}
   
@@ -34,7 +34,7 @@ jobs:
       REVIEWERS: ${{ toJSON(github.event.pull_request.requested_reviewers) }}
     steps:
       - name: Backporting
-        uses: kiegroup/kie-ci/.ci/actions/backporting@main
+        uses: apache/incubator-kie-kogito-pipelines/.ci/actions/backporting@main
         with:
           target-branch: ${{ matrix.target-branch }}
           additional-reviewers: ${REVIEWERS}
diff --git a/.github/workflows/pull_request.yml b/.github/workflows/pull_request.yml
index 8b0a17fd..7970ba63 100644
--- a/.github/workflows/pull_request.yml
+++ b/.github/workflows/pull_request.yml
@@ -30,7 +30,7 @@ jobs:
     steps:
       - name: Support long paths
         if: ${{ matrix.os == 'windows-latest' }}
-        uses: kiegroup/kie-ci/.ci/actions/long-paths@main
+        uses: apache/incubator-kie-kogito-pipelines/.ci/actions/long-paths@main
       - name: Sets the migration env variable on Windows
         if: runner.os == 'Windows'
         run: echo "MIGRATE_TO_9=${{ github.base_ref == 'development' }}" >> $env:GITHUB_ENV
@@ -38,17 +38,17 @@ jobs:
         if: runner.os != 'Windows'
         run: echo "MIGRATE_TO_9=${{ github.base_ref == 'development' }}" >> $GITHUB_ENV
       - name: Java and Maven Setup
-        uses: kiegroup/kie-ci/.ci/actions/maven@main
+        uses: apache/incubator-kie-kogito-pipelines/.ci/actions/maven@main
         with:
           java-version: ${{ matrix.java-version }}
           maven-version: ${{ matrix.maven-version }}
           cache-key-prefix: ${{ runner.os }}-${{ matrix.java-version }}-maven${{ matrix.maven-version }}
       - name: Build Chain
-        uses: kiegroup/kie-ci/.ci/actions/build-chain@main
+        uses: apache/incubator-kie-kogito-pipelines/.ci/actions/build-chain@main
         with:
-          definition-file: https://raw.githubusercontent.com/${GROUP:kiegroup}/optaplanner/${BRANCH:main}/.ci/buildchain-config.yaml
+          definition-file: https://raw.githubusercontent.com/${GROUP:apache}/incubator-kie-optaplanner/${BRANCH:main}/.ci/buildchain-config.yaml
           annotations-prefix: ${{ runner.os }}-${{ matrix.java-version }}/${{ matrix.maven-version }}
           github-token: "${{ secrets.GITHUB_TOKEN }}"
       - name: Surefire Report
-        uses: kiegroup/kie-ci/.ci/actions/surefire-report@main
+        uses: apache/incubator-kie-kogito-pipelines/.ci/actions/surefire-report@main
         if: ${{ always() }}
diff --git a/.github/workflows/quarkus-snapshot.yml b/.github/workflows/quarkus-snapshot.yml
index 57987911..2d933e1c 100644
--- a/.github/workflows/quarkus-snapshot.yml
+++ b/.github/workflows/quarkus-snapshot.yml
@@ -32,7 +32,7 @@ jobs:
         run: sudo add-apt-repository ppa:rmescandon/yq && sudo apt update && sudo apt install yq -y
 
       - name: Java and Maven Setup
-        uses: kiegroup/kie-ci/.ci/actions/maven@main
+        uses: apache/incubator-kie-kogito-pipelines/.ci/actions/maven@main
         with:
           java-version: ${{ matrix.java-version }}
           maven-version: ${{ matrix.maven-version }}
diff --git a/.github/workflows/rhbop_productized_pull_request.yml b/.github/workflows/rhbop_productized_pull_request.yml
deleted file mode 100644
index ca0a9ea6..00000000
--- a/.github/workflows/rhbop_productized_pull_request.yml
+++ /dev/null
@@ -1,57 +0,0 @@
-# Tests RHBOP productized profile builds on PRs
-name: Productized Build Chain
-
-on:
-  pull_request:
-    types: [opened, synchronize, reopened, labeled]
-    branches:
-      - main
-      - 8.*
-    paths-ignore:
-      - 'LICENSE*'
-      - '.gitignore'
-      - '.gitattributes'
-      - '**.md'
-      - '**.adoc'
-      - '*.txt'
-      - '.ci/jenkins/**'
-
-defaults:
-  run:
-    shell: bash
-
-jobs:
-  productized-build-chain:
-    concurrency:
-      group: rhbop_pull_request-${{ github.event_name }}-${{ github.head_ref }}-${{ matrix.os }}-${{ matrix.java-version }}
-      cancel-in-progress: true
-    timeout-minutes: 120
-    strategy:
-      matrix:
-        os: [ubuntu-latest]
-        java-version: [17]
-        maven-version: ['3.8.7']
-      fail-fast: false
-    runs-on: ${{ matrix.os }}
-    name: ${{ matrix.os }} - Java ${{ matrix.java-version }} - Maven
-    steps:
-      - name: Clean Disk Space
-        uses: kiegroup/kie-ci/.ci/actions/ubuntu-disk-space@main
-      - name: Java and Maven Setup
-        uses: kiegroup/kie-ci/.ci/actions/maven@main
-        with:
-          java-version: ${{ matrix.java-version }}
-          maven-version: ${{ matrix.maven-version }}
-          cache-key-prefix: ${{ runner.os }}-${{ matrix.java-version }}-maven${{ matrix.maven-version }}
-      - name: Productized Build Chain
-        uses: kiegroup/kie-ci/.ci/actions/build-chain@main
-        with:
-          definition-file: https://raw.githubusercontent.com/${GROUP:kiegroup}/optaplanner/${BRANCH:main}/.ci/pull-request-config-rhbop.yaml
-          annotations-prefix: ${{ runner.os }}-${{ matrix.java-version }}/${{ matrix.maven-version }}
-          github-token: "${{ secrets.GITHUB_TOKEN }}"
-      - name: Surefire Report
-        uses: kiegroup/kie-ci/.ci/actions/surefire-report@main
-        if: ${{ always() }}
-        with:
-          report_paths: '**/*-reports/TEST-*.xml'
-


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org
For additional commands, e-mail: commits-help@kie.apache.org