33/71
Sign inSign up free

798. Build, Test, Then Deploy

medium 20 XP ~8 minHands-on lab

In /home/student/repos/auth-gateway/.github/workflows/pipeline.yml, the jobs lint, test and deploy all start at the same time. Twice last month, deploy shipped code whose tests were failing, and it also runs for pull requests, which it must never do.

Task

Change pipeline.yml so that:

  • deploy starts only after both lint and test have succeeded,
  • deploy runs only for pushes to the main branch (not for pull requests, not for other branches),
  • lint and test still run in parallel, for every trigger,
  • steps and triggers stay as they are.

About this machine

Ubuntu 24.04 with no internet access. You are student with passwordless sudo. The grader checks the final state of the machine, not the commands you typed. Values like names and ports are generated for you.

Teaching or writing about this? Embed this lab on your page

TerminalNot started

Your machine is ready to start

A fresh, isolated Ubuntu machine boots in a few seconds with the task already set up.

No account needed: 3 of 3 free tries left. Guest machines last 30 minutes.