Uncodemy Logo ← Back to Course
Jenkins · Topic 7 of 15

Linked Jobs: Upstream & Downstream

Accessing a Private Repo

Before chaining jobs, note how to connect a private GitHub repo:

  1. Install Git on the AWS terminal: yum install git -y
  2. On GitHub: Profile Settings → Developer settings → Personal access tokens → Tokens (classic) → Generate new token, and select the repo scope.
  3. In Jenkins: Credentials → Add credentials → select Username & Password → Username = GitHub username, Password = the generated token → Description = github-credentials → Save.

What Are Linked Jobs?

Linked jobs are used when one job needs to trigger another job as part of a larger execution sequence.

Example Chain

JOB-1 → JOB-2 → JOB-3 → JOB-4

Upstream/downstream chaining lets you orchestrate the exact order of execution for different operations.

How to Configure

  1. Create Job-1 and save.
  2. Create Job-2 → Configure → Build Triggers → check "Build after other projects are built" → type task-1 under "Projects to watch" → choose the trigger condition (only if stable, even if unstable, even if fails, or always).
  3. Repeat similarly for Job-3 and Job-4, watching the correct previous jobs.

Once Job-1 is built successfully, all the linked downstream jobs build automatically in sequence. Opening any job shows its Upstream Projects and Downstream Projects sections.

Master Jenkins & DevOps with Uncodemy

Hands-on live training, real projects, and placement support — become job-ready in DevOps.

Enroll in DevOps Training →