Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 0 additions & 25 deletions JenkinsJobs/Releng/FOLDER.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -124,31 +124,6 @@ It must match the name of the build on the build machine.
}
}

pipelineJob('Releng/tagEclipseRelease'){
displayName('Tag Eclipse Release')
description('Tag promoted builds.')
parameters {
stringParam('tag', null, '''\
R is used for release builds. For example: R4_25
S is used for milestones and includes the milestone version. For example: S4_25_0_RC2
''')
stringParam('buildID', null, 'I-build ID of the build that was promoted, for example: I20220831-1800')
stringParam('annotation', null, '''\
GitHub issue to track tagging the release, for example:
'https://github.com/eclipse-platform/eclipse.platform.releng.aggregator/issues/3058' - Tag Eclipse 4.36 release
''')
}
definition {
cpsScm {
lightweight(true)
scm {
github('eclipse-platform/eclipse.platform.releng.aggregator', 'master')
}
scriptPath('JenkinsJobs/Releng/tagEclipseRelease.jenkinsfile')
}
}
}

pipelineJob('Releng/publishPromotedBuild'){
displayName('Publish Promoted Build')
description('''\
Expand Down
60 changes: 44 additions & 16 deletions JenkinsJobs/Releng/promoteBuild.jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -86,9 +86,22 @@ pipeline {
assignEnvVariable('SIGNOFF_BUG', "https://github.com/eclipse-platform/eclipse.platform.releng.aggregator/issues/${SIGNOFF_BUG}")
}
assignEnvVariable('SIGNOFF_BUG_LABEL', env.SIGNOFF_BUG.replace('https://github.com/','').replace('/issues/','#'))

def serviceVersionSegment = (env.CHECKPOINT || env.BUILD_SERVICE != '0') ? ('_' + env.BUILD_SERVICE) : ''
assignEnvVariable('TAG', "${DL_TYPE}${BUILD_MAJOR}_${BUILD_MINOR}${serviceVersionSegment}${env.CHECKPOINT ? ('_' + env.CHECKPOINT) : ''}")
}
}
}
stage('Checkout Git') {
steps {
dir("${WORKSPACE}/repository") {
checkout scm
sh '''#!/bin/bash -xe
git fetch origin tag "${REPO_ID}"
git checkout "${REPO_ID}"
# Check out all submodules at the specified REPO_ID
git submodule update --init --recursive --depth 1

git config --global user.email '[email protected]'
git config --global user.name 'Eclipse Releng Bot'
'''
}
}
}
Expand Down Expand Up @@ -137,11 +150,32 @@ pipeline {
}
}
}
build job: 'Releng/tagEclipseRelease', wait: true, propagate: true, parameters: [
string(name: 'tag', value: "${TAG}"),
string(name: 'buildID', value: "${DROP_ID}"),
string(name: 'annotation', value: "${SIGNOFF_BUG}")
]
}
}
stage('Tag Build') {
environment {
TAG = "${DL_TYPE}${BUILD_MAJOR}_${BUILD_MINOR}${(CHECKPOINT || BUILD_SERVICE != '0') ? ('_' + BUILD_SERVICE) : ''}${CHECKPOINT ? ('_' + CHECKPOINT) : ''}"
}
steps {
dir("${WORKSPACE}/repository") {
sshagent(['github-bot-ssh']) {
sh '''#!/bin/bash -xe
function tagBuild() {
pushURL=$(git config remote.origin.url)
if [[ "$pushURL" == http* ]]; then
# Change to SSH, if the configured URL uses HTTPS (we can only push with SSH)
pushURL=$(echo $pushURL|sed --expression 's|https://github.com/|[email protected]:|')
fi
git tag -a -m "${SIGNOFF_BUG}" ${TAG} HEAD
# git push fails if the tag already exists
git push --verbose ${pushURL} tag ${TAG}
}
tagBuild
export -f tagBuild
git submodule foreach 'tagBuild'
'''
}
}
}
}
stage('Promote P2 Repository') {
Expand All @@ -152,19 +186,13 @@ pipeline {
dir("${WORKSPACE}/updates") {
sshagent(['projects-storage.eclipse.org-bot-ssh']) {
sh '''#!/bin/bash -xe
git clone --depth=1 --filter=tree:0 --no-checkout --branch=master https://github.com/eclipse-platform/eclipse.platform.releng.aggregator.git
pushd eclipse.platform.releng.aggregator
git sparse-checkout set --no-cone eclipse-platform-parent/pom.xml
git checkout
popd

sourceRepo="eclipse/updates/${BUILD_REPO_ORIGINAL}/${REPO_ID}"
targetRepo="eclipse/updates/${REPO_SITE_SEGMENT}/${DL_DROP_ID}"
ssh [email protected] cp -r "${EP_ROOT}/${sourceRepo}/." "${EP_ROOT}/${targetRepo}"

MIRRORS_URL="https://www.eclipse.org/downloads/download.php?file=/${targetRepo}"
mvn tycho-p2-repository:modify-repository-properties -Pp2-repository-modification \\
--file eclipse.platform.releng.aggregator/eclipse-platform-parent/ \\
--file ${WORKSPACE}/repository/eclipse-platform-parent/pom.xml \\
-Dp2.repository.location=https://download.eclipse.org/${sourceRepo}/ \\
-Dp2.repository.output=$(pwd)/output \\
-Dp2.repository.kind=artifact \\
Expand All @@ -179,7 +207,7 @@ pipeline {
}
post {
always {
archiveArtifacts '**/*'
archiveArtifacts artifacts: '**/*', excludes: 'repository/**'
}
}
}
Expand Down
56 changes: 0 additions & 56 deletions JenkinsJobs/Releng/tagEclipseRelease.jenkinsfile

This file was deleted.

1 change: 0 additions & 1 deletion RELEASE.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@
- SIGNOFF_BUG: Needs to be updated to sign-off issue (numeric part only)
- TRAIN_NAME: Whenever the current GA release is planned for (formatted 4 digit year - 2 digit month, i.e `2022-06`)
- After the build find and open the mail template [artifact](https://ci.eclipse.org/releng/job/Releng/job/promoteBuild/lastSuccessfulBuild/artifact/) and have it ready.
- This should automatically run [tag Eclipse release](https://ci.eclipse.org/releng/job/Releng/job/tagEclipseRelease/) to tag the source code.
* Contribute to SimRel
- If you have not already set up SimRel you can do so using Auto Launch [here](https://www.eclipse.org/setups/installer/?url=https://git.eclipse.org/c/oomph/org.eclipse.oomph.git/plain/setups/interim/SimultaneousReleaseTrainConfiguration.setup&show=true)
- Clone [org.eclipse.simrel.build](https://git.eclipse.org/c/simrel/org.eclipse.simrel.build.git) (Should have been done by the installer during set up, but make sure you have latest).
Expand Down
Loading