0

How to establish connection between Jenkins jobs hosted on different server with out using master slave concept

I need to send the parameters from one Jenkins server to another both were hosted in different server;

and i need to trigger a down stream project in another Jenkins server

soundararajan.c
  • 2,538
  • 6
  • 29
  • 51

1 Answers1

1

You can use Parameterized remote trigger plugin: https://wiki.jenkins.io/display/JENKINS/Parameterized+Remote+Trigger+Plugin There are two parts to use this plugin-

  1. Configuration - Go to Manage Jenkins -> Configure System -> Parameterized Remote Trigger Configuration fill the parameters as appropriate and check the connection using 'validate address' button. If it is validated successfully you are good to go.
  2. Calling a job on remote server - In your job you can add a build step "trigger remote parameterized job". Fill in the remote server name, poll interval, job name and other parameters. Now when you will run your job, it will trigger the job on remote server and will check for status on the interval given in poll interval option.
  • followed the same, it returns: "Triggering this remote job: test Not checking if the remote job test is building. Triggering remote job now." ``Server returned HTTP response code: 403 for URL: http://x.xx.xx.x:8080/job/test/buildWithParameters?token=test&build_number=8&delay=0 Connection to remote server failed, waiting for to retry - 20 seconds until next attempt.`` – soundararajan.c Jul 28 '17 at 09:49
  • code 403 means unauthorized access error. Are you using any authentication? try using 'Use the credentials plugin' option and make sure the user you are authenticating with has rights to trigger build on remote server. – Rahul Sharma Jul 28 '17 at 15:14
  • Yes using the username/password. (enabled credentials plugin already). using admin credentials of remote server for triggering. after this also same error – soundararajan.c Jul 31 '17 at 05:45