Skip to content

Commit 53f5ed4

Browse files
authored
GLSP-1607: Fix deployment (#120)
Update jenkins job to pass its artifact url to the deployment job. This ensures that the deployment job can download the build client bundles before building the update site Fixes eclipse-glsp/glsp/issues/1607
1 parent bdfd7fe commit 53f5ed4

File tree

1 file changed

+14
-20
lines changed

1 file changed

+14
-20
lines changed

Jenkinsfile

Lines changed: 14 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ kind: Pod
44
spec:
55
containers:
66
- name: ci
7-
image: eclipseglsp/ci:alpine-v7.0
7+
image: eclipseglsp/ci:alpine-v7.1
88
resources:
99
limits:
1010
memory: "2Gi"
@@ -31,8 +31,6 @@ spec:
3131
readOnly: true
3232
- name: m2-repo
3333
mountPath: /home/jenkins/.m2/repository
34-
- name: volume-known-hosts
35-
mountPath: /home/jenkins/.ssh
3634
volumes:
3735
- name: "jenkins-home"
3836
emptyDir: {}
@@ -46,9 +44,6 @@ spec:
4644
path: settings.xml
4745
- name: m2-repo
4846
emptyDir: {}
49-
- name: volume-known-hosts
50-
configMap:
51-
name: known-hosts
5247
"""
5348
pipeline {
5449
agent {
@@ -106,9 +101,10 @@ pipeline {
106101
if (sh(returnStatus: true, script: 'git diff --name-only | grep -q "^client/yarn.lock"') == 0) {
107102
echo 'The yarn.lock file has uncommited changes!'
108103
error 'The yarn.lock file has uncommited changes!'
109-
}
104+
}
110105
}
111106
}
107+
archiveArtifacts artifacts: 'client/examples/workflow-webapp/app/**', fingerprint: true
112108
}
113109
}
114110
}
@@ -152,23 +148,21 @@ pipeline {
152148
}
153149

154150
stage('Deploy (master only)') {
155-
when {
151+
when {
156152
allOf {
157-
branch 'master';
158-
expression {
159-
/* Only trigger the deployment job if the changeset contains changes in
160-
the `server` or `client/packages/` directory */
161-
sh(returnStatus: true, script: 'git diff --name-only HEAD^ | grep -q "^server"') == 0
153+
branch 'master'
154+
expression {
155+
/* Only trigger deployment if the changeset contains changes in `server` or `client/packages` directories */
156+
sh(returnStatus: true, script: 'git diff --name-only HEAD^ | grep -q "^server\\|^client"') == 0
162157
}
163158
}
164159
}
165-
stages {
166-
stage('Deploy server (P2)') {
167-
steps {
168-
build job: 'deploy-ide-p2-nightly', wait: false
169-
}
170-
171-
}
160+
steps {
161+
build job: 'deploy-ide-p2-nightly',
162+
wait: false,
163+
parameters: [
164+
string(name: 'ARTIFACT_URL', value: "${env.BUILD_URL}artifact/client/examples/workflow-webapp/app/*zip*/app.zip")
165+
]
172166
}
173167
}
174168
}

0 commit comments

Comments
 (0)