How to define rules in gitlab "stages" so that no need to define separate rules for jobs

Suppose there are 4 jobs are define in stages .


  • build
  • test
  • deploy
  • upload

Now test, deploy and upload only run when pipeline trigger manually. We can define rule on separate jobs for this but it will be repetitive.(do not want to use that)

Is it possible to define rule on "stages" so that one job will run on automatic trigger and rest 3 job will run on manual trigger of pipeline.

How many English words
do you know?
Test your English vocabulary size, and measure
how many words do you know
Online Test
Powered by Examplum