GitLab CI Deploys Before the Tests Finish
The GitLab pipeline in /home/student/repos/data-pipeline/.gitlab-ci.yml starts all five jobs at the same moment. The tests sometimes fail because the build isn't finished, and last week deploy shipped while unit was still failing.
Without changing any job's script:
build, test and deploy, in that order, and put build in build, lint, unit and e2e in test, and deploy in deploy,lint doesn't need the build: it must start immediately when the pipeline starts,unit and e2e must start as soon as build has finished, without waiting for anything else,deploy must still wait until build, lint, unit and e2e have all succeeded.There's no GitLab here: the grader reads your YAML.
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.
Part of CI/CD Pipelines in Practice. Next step: Replace only/except With rules in GitLab CI
Teaching or writing about this? Embed this lab on your page
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.