Hello, It seems one (not so good) solution is to disable giving the SHA1 to jenkins in the hook on the Stash server that notifies Jenkins. There is an option you can disable so that the SHA1 is not given when triggering the corresponding jenkins job. Not optimal because Stash is not in control anymore about what must be built.
Best regards Tom, On Monday, 20 April 2015 12:47:13 UTC+2, Tom Deblauwe wrote: > > Hello, > > I am using the "groovy CPS DSL from SCM" as my configuration for my > workflow. This works well and reads the scripts from my "workflows.git" > reposity. > > In the workflow script itself, I start with: > > node { > git branch: '**', changelog: false, poll: true, url: > 'ssh://git@stash:7999/my/project.git' > } > > I have configured my Stash gitserver to notify Jenkins about a push to my > code repository. In the configuration of my workflow job, I need to enable > "Poll SCM" but without any timings defined for this to work. > So the problem is, that I get a notification from Stash with a commit id > from the "project.git" repository(as expected), but jenkins tries to > checkout that commit in the "workflows.git" repository, NOT the > "project.git" repository. It doesn't exist there, so the job fails. > > So how can I have my workflows scripts in a git repository, and at the > same time use an external trigger to start the build? > > Best regards, > Tom, > -- 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 jenkinsci-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/492c4448-a10d-40c1-85dc-da07af0e477d%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.