How to specify branch in .gitlab-ci.yml for a submodule (different repo) in gitlab-ci?
You don't. You specify it in the .gitmodules
file of the project you are building.
[submodule "MyRepo"]
path = MyRepo
url = https://github.com/vendor/MyRepo.git
branch = master