Skip to content

Commit

Permalink
NO-ISSUE: Release job updates and fixes for Apache 10 release (#2597)
Browse files Browse the repository at this point in the history
  • Loading branch information
rodrigonull authored Sep 19, 2024
1 parent e21bbd8 commit 1c731ec
Show file tree
Hide file tree
Showing 42 changed files with 1,215 additions and 874 deletions.
2 changes: 1 addition & 1 deletion .ci/jenkins/Jenkinsfile.daily-dev-publish
Original file line number Diff line number Diff line change
Expand Up @@ -596,7 +596,7 @@ pipeline {
steps {
dir('kie-tools') {
script {
withCredentials([usernamePassword(credentialsId: "${pipelineVars.mavenDeployRepositoryCredentialsId}", usernameVariable: 'REPOSITORY_USER', passwordVariable: 'REPOSITORY_TOKEN')]) {
withCredentials([usernamePassword(credentialsId: "${pipelineVars.mavenDeploySnapshotsCredentialsId}", usernameVariable: 'REPOSITORY_USER', passwordVariable: 'REPOSITORY_TOKEN')]) {
configFileProvider([configFile(fileId: "${pipelineVars.mavenSettingsConfigFileId}", variable: 'MAVEN_SETTINGS_FILE')]) {
sh """#!/bin/bash -el
export KIE_TOOLS_BUILD__mavenDeploySkip=false
Expand Down
886 changes: 458 additions & 428 deletions .ci/jenkins/Jenkinsfile.release-build

Large diffs are not rendered by default.

14 changes: 6 additions & 8 deletions .ci/jenkins/Jenkinsfile.release-candidate
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,10 @@ pipeline {
}

parameters {
string(name: 'BRANCH_NAME', description: 'Set the Git branch to checkout (0.0.X)', trim: true)
string(name: 'BRANCH_NAME', description: 'Set the Git branch to checkout (0.0.x)', trim: true)
string(name: 'RELEASE_VERSION', description: 'Release version', trim: true)
string(name: 'TAG_NAME', description: 'Tag name to be created', trim: true)
string(description: 'Runners', name: 'RUNNERS', defaultValue: '{"chrome_extensions":"true","cors_proxy_image":"true","dashbuilder_viewer_image":"true","dev_deployment_base_image":"true","dev_deployment_dmn_form_webapp_image":"true","dev_deployment_kogito_quakus_blank_app_image":"true","dev_deployment_upload_service":"true","extended_services":"true","jbpm_quarkus_devui":"true","kie_sandbox_extended_services_image":"true","kie_sandbox_helm_chart":"true","kie_sandbox_image":"true","kn_plugin_workflow":"true","kogito_task_console":"true","kogito_management_console":"true","kogito_swf_builder":"true","kogito_swf_devmode":"true","kogito_serverless_operator":"true","npm_packages":"true","online_editor":"true","runtime_tools_consoles_helm_chart":"true","serverless_logic_web_tools":"true","serverless_logic_web_tools_base_builder_image":"true","serverless_logic_web_tools_swf_builder_image":"true","serverless_logic_web_tools_swf_dev_mode_image":"true","standalone_editors_cdn":"true","sonataflow_quarkus_devui":"true","vscode_extensions_dev":"true","vscode_extensions_prod":"true"}')
}

stages {
Expand Down Expand Up @@ -71,7 +72,7 @@ pipeline {
steps {
dir('kie-tools') {
script {
buildUtils.setupPnpm()
buildUtils.setupPnpm("${pipelineVars.mavenSettingsConfigFileId}")
}
}
}
Expand All @@ -81,7 +82,7 @@ pipeline {
steps {
dir('kie-tools') {
script {
buildUtils.pnpmBootstrap("${env.PNPM_FILTER_STRING}")
buildUtils.pnpmBootstrap()
}
}
}
Expand Down Expand Up @@ -131,15 +132,14 @@ pipeline {
}
}

stage('Commit and Push changes') {
stage('Commit changes') {
steps {
dir('kie-tools') {
script {
sh """#!/bin/bash -el
git add .
git commit --allow-empty -am "Apache KIE ${params.RELEASE_VERSION} release"
""".trim()
githubUtils.pushObject('origin', "${params.NEW_BRANCH_NAME}", "${pipelineVars.asfGithubPushCredentialsId}")
}
}
}
Expand Down Expand Up @@ -173,11 +173,9 @@ pipeline {
steps {
build job: 'KIE/kie-tools/kie-tools-release-build', parameters: [
booleanParam(name: 'DRY_RUN', value: false),
string(name: 'BASE_REF', value: "${env.BRANCH_NAME}"),
string(name: 'BASE_REF', value: "${env.TAG_NAME}"),
string(name: 'RELEASE_VERSION', value: "${params.RELEASE_VERSION}"),
string(name: 'UPLOAD_ASSET_URL', value: "${env.RELEASE_UPLOAD_ASSET_URL}"),
string(name: 'RUNNERS', value: "${params.RUNNERS}"),
booleanParam(name: 'RELEASE_CANDIDATE', value: true),
string(name: 'RELEASE_CANDIDATE_VERSION', value: "${TAG_NAME}")
]
}
Expand Down
125 changes: 125 additions & 0 deletions .ci/jenkins/Jenkinsfile.release-candidate.quarkus-accelerator
Original file line number Diff line number Diff line change
@@ -0,0 +1,125 @@
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

@Library('jenkins-pipeline-shared-libraries')_

pipeline {
agent {
docker {
image 'docker.io/apache/incubator-kie-tools-ci-build:10.0.999'
args '--shm-size=2g --privileged --group-add docker'
label util.avoidFaultyNodes()
}
}

options {
timeout(time: 60, unit: 'MINUTES')
}

parameters {
string(name: 'BRANCH_NAME', description: 'Set the Git branch to checkout (0.0.999)', trim: true)
string(name: 'RELEASE_VERSION', description: 'Release version', trim: true)
string(name: 'TAG_NAME', description: 'Tag name to be created', trim: true)
}

stages {
stage('Load local shared scripts') {
steps {
script {
pipelineVars = load '.ci/jenkins/shared-scripts/pipelineVars.groovy'
githubUtils = load '.ci/jenkins/shared-scripts/githubUtils.groovy'
}
}
}

stage('Clean workspace') {
steps {
cleanWs(deleteDirs: true, disableDeferredWipeout: true)
}
}

stage('Checkout kie-sandbox-quarkus-accelerator') {
steps {
dir('kie-sandbox-quarkus-accelerator') {
script {
githubUtils.checkoutRepo(
'http://github.com/apache/incubator-kie-sandbox-quarkus-accelerator.git',
"${params.BRANCH_NAME}",
"${pipelineVars.kieToolsBotGithubCredentialsId}"
)
}
}
}
}

stage('Setup Git repository') {
steps {
dir('kie-sandbox-quarkus-accelerator') {
script {
sh """#!/bin/bash -el
git config user.email [email protected]
git config user.name asf-ci-kie
git checkout ${params.BRANCH_NAME}
""".trim()
}
}
}
}

stage('Update kogito BOM version') {
steps {
dir('kie-sandbox-quarkus-accelerator') {
script {
sh """#!/bin/bash -el
mvn versions:set-property -Dproperty=kogito.bom.version -DnewVersion=${params.RELEASE_VERSION}
""".trim()
}
}
}
}

stage('Commit changes') {
steps {
dir('kie-sandbox-quarkus-accelerator') {
script {
sh """#!/bin/bash -el
git add .
git commit --allow-empty -am "Apache KIE ${params.RELEASE_VERSION} release"
""".trim()
}
}
}
}

stage('Create a new tag') {
steps {
dir('kie-sandbox-quarkus-accelerator') {
script {
githubUtils.createTag("${params.TAG_NAME}")
githubUtils.pushObject('origin', "${params.TAG_NAME}", "${pipelineVars.asfCIGithubCredentialsId}")
}
}
}
}
}

post {
always {
cleanWs(deleteDirs: true, disableDeferredWipeout: true)
}
}
}
2 changes: 1 addition & 1 deletion .ci/jenkins/Jenkinsfile.release-dry-run
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ pipeline {
build job: 'KIE/kie-tools/kie-tools-release-build', parameters: [
booleanParam(name: 'DRY_RUN', value: true),
string(name: 'BASE_REF', value: 'main'),
string(name: 'RUNNERS', value: '{"dev_deployment_base_image":"true","dev_deployment_kogito_quakus_blank_app_image":"true","dev_deployment_dmn_form_webapp_image":"true","dev_deployment_upload_service":"true","kie_sandbox_image":"true","kie_sandbox_extended_services_image":"true","cors_proxy_image":"true","online_editor":"true","chrome_extensions":"true","vscode_extensions_dev":"true","vscode_extensions_prod":"true","npm_packages":"true","standalone_editors_cdn":"true","extended_services":"true","serverless_logic_web_tools":"true","serverless_logic_web_tools_swf_builder_image":"true","serverless_logic_web_tools_base_builder_image":"true","serverless_logic_web_tools_swf_dev_mode_image":"true","dashbuilder_viewer_image":"true","kn_plugin_workflow":"true","kie_sandbox_helm_chart":"true","kogito_task_console":"true","kogito_management_console":"true","kogito_swf_builder":"true","kogito_swf_devmode":"true","kogito_serverless_operator":"true","jbpm_quarkus_devui":"false","sonataflow_quarkus_devui":"false","runtime_tools_consoles_helm_chart":"false"}')
string(name: 'RUNNERS', value: '{"chrome_extensions":"true","cors_proxy_image":"true","dashbuilder_viewer_image":"true","dev_deployment_base_image":"true","dev_deployment_dmn_form_webapp_image":"true","dev_deployment_kogito_quakus_blank_app_image":"true","dev_deployment_upload_service":"true","extended_services":"true","jbpm_quarkus_devui":"true","kie_sandbox_extended_services_image":"true","kie_sandbox_helm_chart":"true","kie_sandbox_image":"true","kn_plugin_workflow":"true","kogito_task_console":"true","kogito_management_console":"true","kogito_swf_builder":"true","kogito_swf_devmode":"true","kogito_serverless_operator":"true","npm_packages":"true","online_editor":"true","runtime_tools_consoles_helm_chart":"true","serverless_logic_web_tools":"true","serverless_logic_web_tools_base_builder_image":"true","serverless_logic_web_tools_swf_builder_image":"true","serverless_logic_web_tools_swf_dev_mode_image":"true","standalone_editors_cdn":"true","sonataflow_quarkus_devui":"true","vscode_extensions_dev":"true","vscode_extensions_prod":"true"}')
]
}
}
Expand Down
2 changes: 1 addition & 1 deletion .ci/jenkins/Jenkinsfile.release-publish
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ pipeline {

parameters {
string(description: 'Release Version', name: 'RELEASE_VERSION', defaultValue: '0.0.0')
string(description: 'Runners', name: 'RUNNERS', defaultValue: '{"dev_deployment_base_image":"true","dev_deployment_kogito_quakus_blank_app_image":"true","dev_deployment_dmn_form_webapp_image":"true","dev_deployment_upload_service":"true","kie_sandbox_image":"true","kie_sandbox_extended_services_image":"true","cors_proxy_image":"true","online_editor":"true","chrome_extensions":"true","vscode_extensions_dev":"true","vscode_extensions_prod":"true","npm_packages":"true","standalone_editors_cdn":"true","extended_services":"true","serverless_logic_web_tools":"true","serverless_logic_web_tools_swf_builder_image":"true","serverless_logic_web_tools_base_builder_image":"true","serverless_logic_web_tools_swf_dev_mode_image":"true","dashbuilder_viewer_image":"true","kn_plugin_workflow":"true","kie_sandbox_helm_chart":"true","kogito_task_console":"true","kogito_management_console":"true","kogito_swf_builder":"true","kogito_serverless_operator":"true","jbpm_quarkus_devui":"true","sonataflow_quarkus_devui":"true","runtime_tools_consoles_helm_chart":"true"}')
string(description: 'Runners', name: 'RUNNERS', defaultValue: '{"chrome_extensions":"true","cors_proxy_image":"true","dashbuilder_viewer_image":"true","dev_deployment_base_image":"true","dev_deployment_dmn_form_webapp_image":"true","dev_deployment_kogito_quakus_blank_app_image":"true","dev_deployment_upload_service":"true","extended_services":"true","jbpm_quarkus_devui":"true","kie_sandbox_extended_services_image":"true","kie_sandbox_helm_chart":"true","kie_sandbox_image":"true","kn_plugin_workflow":"true","kogito_task_console":"true","kogito_management_console":"true","kogito_swf_builder":"true","kogito_swf_devmode":"true","kogito_serverless_operator":"true","npm_packages":"true","online_editor":"true","runtime_tools_consoles_helm_chart":"true","serverless_logic_web_tools":"true","serverless_logic_web_tools_base_builder_image":"true","serverless_logic_web_tools_swf_builder_image":"true","serverless_logic_web_tools_swf_dev_mode_image":"true","standalone_editors_cdn":"true","sonataflow_quarkus_devui":"true","vscode_extensions_dev":"true","vscode_extensions_prod":"true"}')
}

stages {
Expand Down
2 changes: 1 addition & 1 deletion .ci/jenkins/Jenkinsfile.weekly-publish
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ pipeline {
steps {
dir('kie-tools') {
script {
withCredentials([usernamePassword(credentialsId: "${pipelineVars.mavenDeployRepositoryCredentialsId}", usernameVariable: 'REPOSITORY_USER', passwordVariable: 'REPOSITORY_TOKEN')]) {
withCredentials([usernamePassword(credentialsId: "${pipelineVars.mavenDeploySnapshotsCredentialsId}", usernameVariable: 'REPOSITORY_USER', passwordVariable: 'REPOSITORY_TOKEN')]) {
configFileProvider([configFile(fileId: "${pipelineVars.mavenSettingsConfigFileId}", variable: 'MAVEN_SETTINGS_FILE')]) {
timestampedSnapshotVersion = getTimestampedSnapshotVersion()
sh """#!/bin/bash -el
Expand Down
Loading

0 comments on commit 1c731ec

Please sign in to comment.