I am trying to build a common YAML file for both push and tag-based triggers. I can build two YAML files and pass them to the triggers setting page in Google cloud build, but I want to have a common file for both of them.
In the push trigger, the YAML consists of unit testing and in the tag-based trigger, the YAML consists of unit testing and containerizing the application to be pushed to the artifact registry. As YAML is a text-formatting language and if/else conditions cannot be incorporated in it, how can I do this in one single file?
If you want any other information, please let me know and looking forward to help, thanks in advance