2

I'm trying to configure Jenkins with Rundeck to run integration tests on Jenkins when Rundeck finishes a deployment job.

I've put webhook url to rundeck job definition, as it specified in docs (https://jenkins-url/plugin/rundeck/webhook/) but it doesn't work because Jenkins requires authentication.

Putting credentials to the url in form userId:password, userName:password or userId:apiToken doesn't help.

Any ideas on how to

  • disable authentication for particular url or
  • enable url http auth (basic auth) or
  • make Rundeck plugin exposing url correctly so it will not require authentication (as it works with github plugin)?
tuxSlayer
  • 2,804
  • 2
  • 20
  • 24
  • In this particular case, I gave some more permissions to anonymous and it worked. In general: I moved to TeamCity :) – tuxSlayer Jan 24 '16 at 11:53

3 Answers3

1

This isn't necessarily the fix you're looking for, but maybe try using the Remote access API of jenkins and add a step to the end of your rundeck deploy job to curl the build url to trigger it.

whitepatrick
  • 251
  • 1
  • 2
  • 9
1

Even you provide authentication as "user:password" along with the hook, it will still take the "anonymouse" user.. When you enable global security, anonymouse user will just have read permissions only.. if you wanted to run or execute anything through hook (in the sense as "anonymouse" user), you will have to enable "matrix authorisation" method from global security.. and then, provide all or necessary permissions for "anonymouse" user. Once you did this, you can invoke "build" or "buildwithparameters" using hook.. Hope this helps you.

Leo Prince
  • 2,019
  • 26
  • 29
1

Rundeck webhook did not work with my setup. Somehow, Rundeck webhook is not working whatever changes I've done with Jenkins.

As an alternative, I used Jenkin's build trigger : Generic Webhook Trigger plugin. It works when my Rundeck jobs completed Succesfully.

https://wiki.jenkins.io/display/JENKINS/Generic+Webhook+Trigger+Plugin

Example below:

http://jenkins-url/generic-webhook-trigger/invoke?token=your-token