-
Notifications
You must be signed in to change notification settings - Fork 317
/
Jenkinsfile
48 lines (43 loc) · 1.29 KB
/
Jenkinsfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
pipeline {
agent any
options {
buildDiscarder(logRotator(numToKeepStr:'15'))
disableConcurrentBuilds()
timeout(time: 120, unit: 'MINUTES')
}
environment {
DOWNLOAD_AREA = '/home/data/httpd/download.eclipse.org/modeling/tmf/xtext'
REPOSITORY_PATH="${DOWNLOAD_AREA}/updates/nightly"
}
tools {
jdk "temurin-jdk17-latest"
}
stages {
stage('Prepare download area') {
steps {
sshagent(['projects-storage.eclipse.org-bot-ssh']) {
sh '''
echo ${REPOSITORY_PATH}
ssh genie.xtext@projects-storage.eclipse.org "mkdir -p $REPOSITORY_PATH"
'''
}
}
}
stage('Maven Tycho Build, Sign, Deploy') {
steps {
withCredentials([file(credentialsId: 'secret-subkeys.asc', variable: 'KEYRING')]) {
sh 'gpg --batch --import "${KEYRING}"'
sh 'for fpr in $(gpg --list-keys --with-colons | awk -F: \'/fpr:/ {print $10}\' | sort -u); do echo -e "5\ny\n" | gpg --batch --command-fd 0 --expert --edit-key ${fpr} trust; done'
}
sshagent(['projects-storage.eclipse.org-bot-ssh']) {
sh './full-deploy.sh -Peclipse-sign,sonatype-oss-release,release-snapshot'
}
}
}
}
post {
success {
archiveArtifacts artifacts: 'build/**'
}
}
}