Template rules for gitlab CI
This small change add rules to gitlab pipeline to prevent/allow it to run in a specific circumstance.
Currently, I only add prevent_other_not_master_rules
to all pipelines as we may not want them to run on others except master or when testing in MR.
The other rules I give you in case you need them.