Hey all!
I have multiple library projects that I build as multibranch pipelines.
Naturally these library projects have dependencies and usually fetch these
dependencies as a SNAPSHOT artifact from a previous build of the other
library.
For the case where a such a dependency gets a change, I want to trigger a
new build for all dependent library builds. These are my Jenkinsfile's for
the two repos:
* in foo.git/Jenkinsfile
#!/usr/bin/env groovy
node {
stage('Test') {
checkout scm
sh "( sleep 5 && echo foo )"
}
}
* in bar.git/Jenkinsfile:
#!/usr/bin/env groovy
properties([
pipelineTriggers([
upstream(
threshold: hudson.model.Result.SUCCESS,
upstreamProjects: 'repos/foo/master'
)
])
])
node {
stage('Test') {
checkout scm
sh "( sleep 5 && echo bar )"
}
}
Both Jenkins projects are saved underneath the directory "repos". Now I
tried several versions how to reference "upstreamProjects", with relative
paths "../../foo/master", "../foo/master" or simply "foo/master", or with
the absolute path like above, but all without success: the "bar.git"
project is just never triggered.
What am I doing wrong? Is this even a supported use case and if not, what
are my alternatives given the above setup?
Thanks in advance,
Thomas.
--
You received this message because you are subscribed to the Google Groups
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/jenkinsci-users/6fc22699-13bc-4814-a49d-f8fef30fd206%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.