Skip to content

Commit fe31258

Browse files
committed
[I/Y/P-Build] Unify and fix artifact archiving and make it more specific
The archiving step in case of build-failures resulted in no artifacts being archived.
1 parent 2e78080 commit fe31258

File tree

2 files changed

+7
-12
lines changed

2 files changed

+7
-12
lines changed

JenkinsJobs/Builds/build.jenkinsfile

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -284,15 +284,10 @@ spec:
284284
sh '''
285285
source $CJE_ROOT/buildproperties.shsource
286286
cp -r $logDir/* $CJE_ROOT/$DROP_DIR/$BUILD_ID/buildlogs
287-
rm -rf $logDir
288287
rm -rf $CJE_ROOT/$DROP_DIR/$BUILD_ID/apitoolingreference
289-
cp $CJE_ROOT/buildproperties.txt $CJE_ROOT/$DROP_DIR/$BUILD_ID
290-
cp $CJE_ROOT/buildproperties.php $CJE_ROOT/$DROP_DIR/$BUILD_ID
291-
cp $CJE_ROOT/buildproperties.properties $CJE_ROOT/$DROP_DIR/$BUILD_ID
292-
cp $CJE_ROOT/buildproperties.shsource $CJE_ROOT/$DROP_DIR/$BUILD_ID
288+
cp $CJE_ROOT/buildproperties.* $CJE_ROOT/$DROP_DIR/$BUILD_ID
293289
cp $CJE_ROOT/$DROP_DIR/$BUILD_ID/buildproperties.* $CJE_ROOT/$EQUINOX_DROP_DIR/$BUILD_ID
294290
'''
295-
archiveArtifacts '**/siteDir/**'
296291
}
297292
}
298293
stage('Promote Eclipse platform'){
@@ -354,11 +349,13 @@ spec:
354349
}
355350
}
356351
post {
352+
always {
353+
archiveArtifacts 'cje-production/siteDir/**'
354+
}
357355
failure {
358356
emailext subject: "${RELEASE_VER} ${BUILD_TYPE}-Build: ${BUILD_IID} - BUILD FAILED",
359357
body: "Please go to ${BUILD_URL}console and check the build failure.", mimeType: 'text/plain',
360358
to: "${BUILD.mailingList}", from:'[email protected]'
361-
archiveArtifacts "${CJE_ROOT}/siteDir/eclipse/downloads/drops4/${BUILD_IID}/gitLog.html, $CJE_ROOT/gitCache/eclipse.platform.releng.aggregator"
362359
}
363360
success {
364361
emailext subject: "${RELEASE_VER} ${BUILD_TYPE}-Build: ${BUILD_IID} ${COMPARATOR_ERRORS_SUBJECT}",

JenkinsJobs/YBuilds/P_build.groovy

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -208,11 +208,6 @@ spec:
208208
}
209209
}
210210
}
211-
stage('Archive artifacts'){
212-
steps {
213-
archiveArtifacts '**/siteDir/**'
214-
}
215-
}
216211
stage('Promote Update Site'){
217212
steps {
218213
container('jnlp') {
@@ -227,6 +222,9 @@ spec:
227222
}
228223
}
229224
post {
225+
always {
226+
archiveArtifacts 'cje-production/siteDir/**'
227+
}
230228
failure {
231229
emailext body: "Please go to <a href='${BUILD_URL}console'>${BUILD_URL}console</a> and check the build failure.<br><br>",
232230
subject: "${env.RELEASE_VER.trim()} P-Build: ${env.BUILD_IID.trim()} - BUILD FAILED",

0 commit comments

Comments
 (0)