Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[releng] Add Jenkins build support and signing
- Loading branch information
1 parent
25d001d
commit d2fde99
Showing
4 changed files
with
97 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
pipeline { | ||
agent { | ||
kubernetes { | ||
label 'migration' | ||
} | ||
} | ||
tools { | ||
maven 'apache-maven-latest' | ||
jdk 'adoptopenjdk-hotspot-jdk8-latest' | ||
} | ||
stages { | ||
stage('Build') { | ||
steps { | ||
|
||
sh "mvn \ | ||
--batch-mode --show-version \ | ||
clean verify \ | ||
-P production \ | ||
-Dmaven.repo.local=/home/jenkins/.m2/repository \ | ||
--settings /home/jenkins/.m2/settings.xml \ | ||
" | ||
} | ||
} | ||
stage('Upload') { | ||
steps { | ||
sshagent ( ['projects-storage.eclipse.org-bot-ssh']) { | ||
sh './scripts/nightly-upload.sh' | ||
} | ||
} | ||
} | ||
} | ||
post { | ||
success { | ||
// if/when tests are added, the results can be collected by uncommenting the next line | ||
// junit '*/*/target/surefire-reports/*.xml' | ||
archiveArtifacts 'repositories/ilg.gnumcueclipse.repository/target/ilg.gnumcueclipse.repository-*.zip' | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
#!/bin/bash | ||
|
||
set -u # run with unset flag error so that missing parameters cause build failure | ||
set -e # error out on any failed commands | ||
set -x # echo all commands used for debugging purposes | ||
|
||
SSHUSER="genie.embed-cdt@projects-storage.eclipse.org" | ||
SSH="ssh ${SSHUSER}" | ||
SCP="scp" | ||
|
||
P2ZIP=repositories/ilg.gnumcueclipse.repository/target/ilg.gnumcueclipse.repository-*.zip | ||
# The download location is chosen to be a non-mirrored URL according to | ||
# https://wiki.eclipse.org/IT_Infrastructure_Doc#Use_mirror_sites.2Fsee_which_mirrors_are_mirroring_my_files.3F | ||
DOWNLOAD=/home/data/httpd/download.eclipse.org/embed-cdt/nightly/${BRANCH_NAME} | ||
|
||
${SSH} rm -rf ${DOWNLOAD}-temp | ||
${SSH} rm -rf ${DOWNLOAD}-last | ||
${SSH} mkdir -p ${DOWNLOAD}-temp | ||
${SCP} ${P2ZIP} ${SSHUSER}:${DOWNLOAD}-temp/ilg.gnumcueclipse.repository.zip | ||
${SSH} "cd ${DOWNLOAD}-temp && unzip ilg.gnumcueclipse.repository.zip" | ||
${SSH} mv ${DOWNLOAD} ${DOWNLOAD}-last | ||
${SSH} mv ${DOWNLOAD}-temp ${DOWNLOAD} | ||
${SSH} rm -rf ${DOWNLOAD}-last |